Build a JavaScript Trivia Bot - Build a JavaScript Trivia Bot

Tell us what’s happening:

It says every step is wrong.. deleted everything but the first console.log and that one once ran was then correct, this is a ridiculous issue. I’m just going to have to copy paste a confirmed solution.. I just wanted to bring this issue to the attention of at least some one..

Your code so far

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

let botName = "Tipy";

let botLocation = "127.0.0.1";

let favoriteLanguage = "JavaScript";

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

console.log("My favorite programming language is " + favoriteLanguage + ".");

let codingFact = favoriteLanguage + " was created by Brendan Eich at Netscape in just 10 days in 1995" + ".";

console.log("codingFact");

codingFact = "Despite its name, " + favoriteLanguage + " is not related to Java; it is a dynamically typed, high-level scripting language that follows the ECMAScript standard.";

console.log(codingFact);

codingFact = favoriteLanguage + " is interpreted rather than compiled, meaning it runs line-by-line in the browser at runtime.";

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 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/142.0.0.0 Safari/537.36

Challenge Information:

Build a JavaScript Trivia Bot - Build a JavaScript Trivia Bot

It is worth figuring out why your code doesn’t work instead of copying an answer from someone

1 Like

This sure looks suspicious to me?

1 Like

I understand, but even a confirmed one did not work.

thanks for spotting that

It seems to all work separately :frowning: what could possibly be wrong.

I suspect you copied a ‘confirmed one’ that was out of date or not correct. I wouldn’t copy code from someone else.

Can you post your updated code with the fix I pointed out?

I’m seeing a pair of syntax errors highlighted in the editor as well as a minor spacing error and a minor punctuation error in the output.

1 Like

makes sense, and here you go.

:down_arrow:

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

let botName = “Tipy”;

let botLocation = “127.0.0.1”;

let favoriteLanguage = “JavaScript”;

console.log("My name is " + botName "and I live on " + botLocation + “.”);

console.log("My favorite programming language is " + favoriteLanguage + “.”);

let codingFact = favoriteLanguage + " was created by Brendan Eich at Netscape in just 10 days in 1995" + “.”;

console.log(codingFact);

codingFact = “Despite its name, " + favoriteLanguage + " is not related to Java; it is a dynamically typed, high-level scripting language that follows the ECMAScript standard.”;

console.log(codingFact);

codingFact = favoriteLanguage + " is interpreted rather than compiled, meaning it runs line-by-line in the browser at runtime.";

console.log(codingFact);

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

I’ve edited your post to improve the readability of the code. When you enter a code block into a forum post, please precede it with three backticks to make it easier to read.

You can also use the “preformatted text” tool in the editor (</>) to add the backticks.

See this post to find the backtick on your keyboard.
Note: Backticks (`) are not single quotes (').

1 Like

This line should be showing a red squggly line, indicating a syntax error. Also you have a spacing error here

Do you know why it says every step is incorrect?

the first step is 1. You should log "Hello! I'm your coding fun fact guide!" to the console.

if I delete everything else it’ll show I did it correctly.

The syntax error breaks your code and prevents the tests from running. (You have two syntax errors)

Could you explain what you can by spacing error? Thanks again for your time.

You are missing a space between a pair of words. If you fix both of your syntax errors and then look at the console output, that should help you see where it is. The spacing error is on the line I quoted, actually pretty close to the syntax error.

ah-ha thanks so much, I also missed a “.“ on the final step as well as a +.

1 Like