What does the break statement do in Python?
Correct answer
D. Exits the nearest enclosing loop
5 views
D. Exits the nearest enclosing loop
5 views
break terminates the innermost loop immediately.
Asked in: Python Interview Control Flow
https://docs.python.org/3/tutorial/controlflow.htmlNot sure why the answer is D? Ask here and get an explanation.