11. Review


#1


// Write your code below!
var count = 0;

while (count < 10) {
    for (i = 10; i <= 10; i--;) {
        console.log("The for loop looped: " + i + " now!");    
    }
    console.log("The while loop looped: " + count + " now!");
    count++;
}
do {
        console.log("The do/while loop only loops once!");    
}while(myCondition);

My output says there is an unexpected token. I can't find where i made a mistake. Can someone pls help me :smiley:!


#2

there shouldn't be a semi-colon after i--


#3

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