Build a JavaScript Trivia Bot - Build a JavaScript Trivia Bot

Tell us what’s happening:

I have no idea what the problem is, steps 14 and 15 just refuse to cooperate lol.

Your code so far

console.log("Hello! I'm your coding fun fact guide!")
let botName = "John";
let botLocation = "Earth";
let favoriteLanguage = "JavaScript";

console.log("My name is John and I live on Earth.")

console.log("My favorite programming language is JavaScript.")

let codingFact = "For visual flair you use " + favoriteLanguage + ".";
console.log(codingFact)

codingFact = "Always use " + favoriteLanguage + "."; 
console.log (codingFact)

codingFact = "Something something " + favoriteLanguage + ".";
console.log(codingFact)

codingFact = "" + favoriteLanguage + " is dumb.";
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 (Windows NT 10.0; Win64; x64; rv:148.0) Gecko/20100101 Firefox/148.0

Challenge Information:

Build a JavaScript Trivia Bot - Build a JavaScript Trivia Bot

Welcome to the forum @cloudyxkai !

You should be using variables in these strings rather than the values assigned to the variables.

And you have logged coding_fact four times, not three.

Happy coding!

the 4th time i forgot to delete before posting but i realized beforehand. i was just trying different things to complete it. after i fixed that, you know what it was? the spaces. i compressed it all so there aren’t empty lines in between stuff and it finally worked. even the lines you quoted worked fine, they came up as completed successfully, it was those spaces. the coder thing can be temperamental lmao.

Hmmm…would you post your updated code, please? If those two lines I quoted were not changed and the tests still passed, we have a test issue to address.

console.log(“Hello! I’m your coding fun fact guide!”)

let botName = “John”;

let botLocation = “Earth”;

let favoriteLanguage = “JavaScript”;

console.log(“My name is John and I live on Earth.”)

console.log(“My favorite programming language is JavaScript.”)

let codingFact = "For visual flair you use " + favoriteLanguage + “.”;

console.log(codingFact)

codingFact = "Always use " + favoriteLanguage + “.”;

console.log (codingFact)

codingFact = "Something something " + favoriteLanguage + “.”;

console.log(codingFact)

console.log("It was fun sharing these facts with you. Goodbye! - “+botName+ " from “+botLocation+”.”)

my code so far yet no.14 still shows an error

Please create your own topic when you have specific questions about your own challenge code. Only respond to another thread when you want to provide help to the original poster of the other thread or have follow up questions concerning other replies given to the original poster.

The easiest way to create a topic for help with your own solution is to click the Help button image located on each challenge. This will automatically import your code in a readable format and pull in the challenge URL while still allowing you to ask any question about the challenge or your code.

Thank you.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.