11.Stuck


#1

Can someone check my code?
I don't really understand the whole loop thing so i'm just copying my previous codes but now it doesn't work..
Thanks!

var loopCondition = false;
var count=13
var understand=true
do {
console.log("I'm gonna stop looping 'cause my condition is " + loopCondition + "!");
} 
while (loopCondition);
for(var count = 1; count < 2; count++) {
    console.log("for loop");
while(understand){
      console.log("Looped once!");
      understand = false;
      }

#2

@carolienvbelle,
The Instructions:
To finish up and prove your loop mastery,
write three syntactically correct loops in the editor:
one for,
one while, and one do. Beware of infinite loops!

the for-loop:
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for

the while-loop:
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/while

the do-while-loop:
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/do...while


#3

Like the poster above said, the point is just to write three loops. You really need to figure out the loops before moving on. The for , while and do while loops are essential.

That said here are some tips:
Your missing a closing curly bracket at the end of your for loop
Make sure to write indent your code properly
separate the loops.
The is no need for you to declare "var count = 13" because the for loop declares it in the condition. No other loop is using it.