183k views
1 vote
If a while loop iterates forever,what is the most likely cause?

User Capurnicus
by
4.4k points

2 Answers

14 votes

Answer:

Runtime error probably. The program won't make it past the while loop in the code.

User Riley Watkins
by
4.2k points
9 votes

Answer: The loop has a condition that cannot possibly be false.

Step-by-step explanation:

If a while loop iterates forever,what is the most likely cause?-example-1
User YosSaL
by
5.1k points