Build a JavaScript Trivia Bot - Build a JavaScript Trivia Bot

Tell us what’s happening:

Please help. I don’t know why my code is not passing as it is outputting correctly. I keep getting the same error message :
15. You should log to the console “It was fun sharing these facts with you. Goodbye! - (botName) from (botLocation).” using concatenation to add the values of the variables.
At first I was using the favoriteLocation first and changed to have the string first, but still just getting the same result.

Your code so far

console.log("Hello! I'm your coding fun fact guide!");
let botName = 'Pica';

let botLocation = 'Chin Island';

let favoriteLanguage = 'Java';
console.log("My name is " + botName + " and I live on " + botLocation + ".");
console.log("My favorite programming language is " + favoriteLanguage + ".");
codingFact = 'A coding fact about ' +  favoriteLanguage;
console.log(codingFact);
codingFact = 'My favorite language is ' + favoriteLanguage;
console.log(codingFact);
codingFact = 'Im having difficutly with '
+ favoriteLanguage;
console.log(codingFact);
console.log("It was fun sharing sharing these facts with you. Goodbye! - " + botName + " from " + botLocation + ".");






Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/140.0.0.0 Safari/537.36 Edg/140.0.0.0

Challenge Information:

Build a JavaScript Trivia Bot - Build a JavaScript Trivia Bot

https://www.freecodecamp.org/learn/full-stack-developer/lab-javascript-trivia-bot/lab-javascript-trivia-bot

1 Like

And as soon as I posted it, I saw my error nevermind

1 Like

I got the same error and i fixed it

if you need help please create your own topic

If you have a question about a specific challenge as it relates to your written code for that challenge and need some help, click the Get Help > Ask for Help button located on the challenge.

The Ask for Help button will create a new topic with all code you have written and include a link to the challenge also. You will still be able to ask any questions in the post before submitting it to the forum.

Thank you.

1 Like