Can someone please find the mistake


#1


https://www.codecademy.com/courses/javascript-beginner-en-ZA2rb/0/5?curriculum_id=506324b3a7dffd00020bf661#


SyntaxError: Unexpected token =

Heading


var phrase = "Two things tell me you're in "; 
var phrase2 = "At least one thing tells me you're not in ";
var season = prompt("What season is it,starting with winter?").toUpperCase();
var month = prompt("What month is it?").toUpperCase();
    switch(season)    {
        case '1':  //winter
            if ((month < 4) || (month >= 12)) {
                console.log(phrase + "winter");
            } 
            else {
                console.log("At least one thing tells me you're not in winter");
            }
        break;
        case '2':  //spring
            if ((month >== 4) && (month < 6))   {
                console.log(phrase + "spring");
            }
            else {
                console.log(phrase2 + "spring");
            }
            break;
        case '3':  //summer
            if ((month >= 6) && (month < 10))   {
            console.log(phrase + "summer");
            }
            else {
                console.log(phrase2 + "summer");
            }
            break;
        case '4':  //fall
            if ((month >= 10) && (month < 12)) {
                console.log(phrase + "fall");
            }
            else {
                console.log(phrase2 + "fall");
            }
            break;
        default:
            console.log("I can't quite figure out what season you're in");
    };


#2

problem is here, you put an additional equal sign. that is not needed :slight_smile:


#3

Thanks for the insight


#4

You're welcome :grin:


#5

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