Build a JavaScript Trivia Bot - Build a JavaScript Trivia Bot

Tell us what’s happening:

It is saying that step 8,9 and 14, 15 are wrong but I am getting the correct result. Did I concat wrong?

Your code so far

console.log("Hello! I'm your coding fun fact guide!");
let botName;
botName = "Sam";
let botLocation;
botLocation = "Planet Earth";
let favoriteLanguage;
favoriteLanguage = "JavaScript";
console.log("My name is" + " " + botName + " " + "and I live on" + " " + botLocation + ".");
console.log("My favorite programming language is" + " " + favoriteLanguage + ".");
let codingFact;
codingFact = "Did you know that" + " " + favoriteLanguage + " " + "is the most popular language to code?"; 
console.log(codingFact);
codingFact = "Did you know that" + " " + favoriteLanguage + " " + "is super easy to learn?";
console.log(codingFact); 
console.log("It was fun sharing these facts with you. Goodbye! -" + " " + botName + " from " + botLocation + ".");

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/136.0.0.0 Safari/537.36

Challenge Information:

Build a JavaScript Trivia Bot - Build a JavaScript Trivia Bot

It seems like the test is expecting the spaces to be part of the text, not separate concatenated spaces. Edit: I think it is only an issue with the second and third console.log tests.

console.log("My name is" + " " + botName + " " + "and I live on" + " " + botLocation + ".");
console.log("My favorite programming language is" + " " + favoriteLanguage + ".");

  1. You should assign a value to codingFact for the third time that also contains favoriteLanguage, and log it to the console.

Did you do this 3 times?


Seeing as it isn’t very clear why the tests fail. It should allow for it, or the requirements should be updated.

I’ll try this, thank you!