0

How do these commands work: break, pass and continue?

Monisha M Edited comment June 1, 2023
User Avatar

Break-The loop is terminated when a criterion is fulfilled, and control is passed to the subsequent statement.
Pass-You can use this when you need a code block syntactically correct but don’t want to run it. This is a null action in essence. When it is run, nothing takes place.
Continue-When a specified criteria is fulfilled, the control is moved to the start of the loop, allowing some parts of the loop currently in execution to be skipped