MY code causes my browser to crash but I'm not sure where the isssue is


#1

//Remember to set your condition outside the loop!
var count = 0;
var loop = function(){
while(count < 3);{ console.log("I'm looping!");
//Your code goes here!
count++;
//if (number === 3) { var condition = false}
}
};

loop();


#2

Hi try to remove the // before your if statement

//if (number === 3) { var condition = false}

#3

still have the same problem of javascript not responding.


#4

Here

while(count < 3); <== this one

First remove the ; after the while condition. Then you should put count less and equal to 3 like that.

while(count <= 3)

Then your if statement you didn't declare number but you declare count so Its should be like that

if (count === 3) {var  count = false}

#5

var count = 0;
var loop = function(){
while(count <= 3){ console.log('I'm looping!');
//Your code goes here!
count++;
if (count === 3) { var count = false}
}
};

loop();
According to the error I'm missing a ), and I have open strings.


#6

Hi try to remove the if statement


#7

Removing if statement doesn't change the error. I'm not sure where I'm missing possible () though.


#8

hi try it like that

var count = 0;
var loop = function(){
	while(count <= 3) { console.log('I'm looping!');
	//Your code goes here!
	count++;
	}
};

loop();

#9

Why do you have another bracket and parentheses after your while( count <= 3)? That parentheses doesn't seem to have a match and isn't it supposed to be while(count < 3)?


#10

talk about picky i missed some string punctuation