Computer Science, asked by amisha9698, 3 months ago

one example of break statement in python ​

Answers

Answered by master3527
1

#!/usr/bin/python for letter in 'Python': # First Example if letter == 'h': break print 'Current Letter :', letter var = 10 # Second Example while var > 0: print 'Current variable value :', var var = var -1 if var == 5: break print "Good bye!"

HOPE IT HELPS YOU.

Answered by dipalee433
5

Answer:

#!/usr/bin/python for letter in 'Python': # First Example if letter == 'h': break print 'Current Letter :', letter var = 10 # Second Example while var > 0: print 'Current variable value :', var var = var -1 if var == 5: break print "Good bye!"


vikasrawat15: hyyy
dipalee433: hey
dipalee433: bol yaar
dipalee433: hey
vikasrawat15: kahaaa rhti ho ab tm
vikasrawat15: baat hu na krti
Similar questions