Whats wrong with my code?


//Remember to make your condition true outside the loop!

var soloLoop = function(){
var soloLoop = true;
while(soloLoop < 0) {
console.log(“Looped once!”);
soloLoop = false;


The error asks me if “Did you log “Looped once!” to the console?”
I don’t understand because i already logged it into the console

Unexpected end of script : Solo flight

You call the function here:


but for some reason you gave it an argument console.log, while your function doesn’t take any arguments




In the variable soloLoop you’ve created, it has like value true so a Boolean value. Here, you’re testing whether soloLoop is less than 0. You can’t test whether true is less than 0. Remove this condition and instead check whether soloLoop is equal to true so it can loop at least one time. Remember to use === sign of comparison instead of = sign for assigning value.