3. for a while... help?


#1


3. for a while


SyntaxError: Unexpected end of input

Could someone tell me what i'm missing ??


var maxRitcher = true;

var trackNumber = Math.random();

while(maxRitcher){
    if (trackNumber < 0.1){

         console.log("song1");

    }else if

    (trackNumber < 0.3){

        console.log("song3");
    
}else if

     (trackNumber < 0.6){

        console.log("song6");

     }else if

     (trackNumber < 0.8){

        console.log("song8");

     }else{

         maxRitcher = false;
         }


#2

you forgot to close while loop


#3

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