27. Conclusion: Part 1


#1

var myColor = "orange"
"orange".length
console.log(myColor.length);
This code is wrong! PLEASE HELP!!!


#2

Your code has everything right except that you don't need the "orange".length on line 2.I hope this helped you good luck!


#3

variables are containers for your value.
you stored "orange"; inside a variable "var myColor"
There's no need to write "orange.length" again.

Although your code should run ordinarily, it does not comply
with the requirement of the chapter, so you have to make sure you
are follow the instructions.

var myColor = "orange";
console.log(myColor.length);
Your code should easily run like this....


#4

I do not know what i did wrong.....


#5

Please check the syntax on console.log. If you've forgotten you can review that lesson here.


#6

I do not know, sometimes proper input causes "Ooops, try again"
wrtiting:
console.log(myColor.length) leaded to "console log is not a function"

thanks anyway.


#7

@cloudrockstar82866, did you get that message in this specific exercise? If yes, was the only thing you changed console.log = (myColor.length) --> console.log(myColor.length);?

If yes, please try refreshing the page and running the program again (after making sure the change is still there). Sometimes once you use code improperly the browser remembers it even after you edit your program and that might be what happened here.


#8

A post was split to a new topic: 27. Why isn't this working?


#9

Your console.log syntax is wrong.
"=" should not be there
is should be be console.log(myColor.length); ---------------------------->see no "=" sign.


#10