0
why the output 6 i`m not understanding
var x = 0; while(x<6) { x++; } document.write(x);
2 Respuestas
+ 2
Loop after loop, x is incremented by 1. When x is 5, 5 is lower than 6, so we enter the loop yet again, in which x is incremented to 6. Then we exit the loop because 6 is not lower than 6, and we print 6.
0
i hate life