A Tricky JavaScript Interview Question Asked by Google and Amazon
Daniel Borowski

Maybe it’s still too early in the morning, but I can’t see how i can reach 4. As I see it, arr.Length is 4 and, since i has been initilized to 0 and the condition states i < arr.Length, the variable’s max value will be 3.