Stuck on More on control flow in JS 7/14!


I am stuck on More on control flow in JS 7/14. I type it in and it comes out wrong! Can you please post the correct code for me?

Replace this line with your code. 

scvar answer = prompt("How are you feeling","Insert Feels Here");

switch(answer) {
  case 'Happy':
    console.log("Yay, I'm happy too!");
  case 'Sad':
    console.log("Aww, too bad!");
  case 'Meh':
    console.log("Have a smile to brighten up your day!");
    console.log("You're a robot...");



I only changed your scvar into var
and tried your code in a windows 8.1 IE11 environment and got a pass....

After you changed your scvar error
maybe you have to do a refresh Browser

++++ reset of session *****************
As you are manipulating with objects
under certain circumstances you can shoot your Browser in an
inconsistent state.

Therefor it is of an advantage to know that you have 2 reset facilities:

One is the use of the F5-key which does a refresh Browser


Two, select&copy your code
Then use the Reset Code button of the course-window,
then paste your code back in.

General Notes:
Always refresh the browser after making corrections:
CTRL f5 ( if on Windows or Linux)
CMD r ( if on a MAC).
CTRL 0 to reset browser zoom


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