Asking for feedback


Can someone please find what is wrong with this piece of code?

var feedback = prompt("please rate the game out of 10");

if (feedback >=8)  {
console.log("Thank you! We should race at the next concert!")
else {
console.log("I'll keep practicing coding and racing.")


Sounds like you've already found something, what makes you say that it is wrong?

(Avoid using words like wrong and working to describe something, because those words do not describe anything)


Can you please say why this piece of code is not working?


I don't even know that it isn't working. Have to start by identifying what what it's doing differently from what you want, otherwise there's no way to know what too look for

If I tell you that my thing is broken, then you'll have a hard time figuring out what I want it to do differently. It's broken though, tell me what's wrong with it.

Not enough information, you say "not working", I have no idea what you mean by that. You have to explain what it shoud do differently.


Well, off the top of my head. You didn't use the correct syntax for console.log..Please review that part of the lesson. Make sure you end it with (:wink:. Test that. Then keep tweaking until you get it the way you want it to display.


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