How is this an infinite loop?


#1

var i = 1;
while(i < 4)
{
console.log("loading…");
};


#2

Because i is staying at one. You are not incrementing i inside of the while loop, so it won't stop because i is staying 1.


#3

Ahh, I see. Thanks very much.