BREAK AND CONTINUE.pptx

visaagan2022 138 views 9 slides Nov 02, 2023
Slide 1
Slide 1 of 9
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9

About This Presentation

wertyuiokiuhytrewfvghedsguiolmjnhg


Slide Content

JUMP STATEMENTS

Jump Statements in Python The jump statement in Python, is used to unconditionally transfer the control from one part of the program to another. There are three keywords to achieve jump statements in Python : break continue

break statement The break statement alters the normal flow of execution as it terminates the current loop and resumes execution of the statement following that loop. The break statement terminates the loop containing it. Control of the program flows to the statement immediately after the body of the loop.

continue statement Continue statement unlike the break statement is used to skip the remaining part of a loop and start with next iteration . When a continue statement is encountered, the control skips the execution of remaining statements inside the body of the loop for the current iteration and jumps to the beginning of the loop for the next iteration.