Basic JavaScript - Declare JavaScript Variables

Tell us what’s happening:
it keeps telling me to declare variable with var and use semicolon at the end. I am doing that. I even do exactly like the hint said and it is still telling me I am wrong. I even typed var ourname; just like the example.

Your code so far

//var myname; = "robert"

Your browser information:

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

Challenge: Basic JavaScript - Declare JavaScript Variables

Link to the challenge:

Hey, you have declared a string variable. You need to create a variable that is not assigned to any value. While creating the variable, consider camelCase.

Welcome to FCC Forum and community!

If you use the example in the lesson and just do your code with the instruction variable, you will pass.
Like you, when I completed this at first, I went that extra step.

Happy coding! :slight_smile:

in the beginning, I did use the example as it was written precisely. var ourname; and it said the same thing. I then went online to see how others did it and that is when I did what you see there.

Fixed it. It helps if i read more closely . it said i had to use “myName” as the variable but i messed up when i saw use the example above part lol.

1 Like

Good going!

Happy coding!