(PCEP) Certified Entry-Level Python Programmer Practice Test

PCEP Using the `else` block in loops 5

Free · Instant Results

What is the output of this code? x = 5 while x > 0: x -= 1 if x == 2: break else: print('loop ended') print('after')
▶ Start Practice Test