Important Notice:

Demonstration of break

Demonstration of break

10 views 1 min read
Program 14: Demonstration of break
 
for i in range(1, 11):
    if i == 6:
        break

    print(i)

Output:

1
2
3
4
5

Related Notes