A

Admin • 828.43K Points
Coach

Q. Which condition will make this loop run forever?
while(?)

  • (A) i > 0
  • (B) true
  • (C) i != 0
  • (D) false
  • Correct Answer - Option(B)
  • Views: 10
  • Filed under category Java
  • Hashtags: Java Loops

Explanation by: Admin
while(true) will cause the loop to run forever unless a break occurs.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.