Mark As Completed Discussion

Try this exercise. Click the correct answer from the options.

What is the result of the execution of following code block?

PYTHON
1a = 5
2while a <= 5:
3    if a < 5:
4        break
5    print(a)

Click the option that best answers the question.

  • The program will loop indefinitely
  • The value of a will be printed once
  • The value of a will be printed 5 times
  • The loop will not be executed