P43continue statement, while loop

# Loop: 



# 1.while infinite loop (while statement + condition)

# When the back while conditions are met (True), it will execute the following code

#while True: # seriously when, as is true by default, so this is an infinite loop
# Print ( "ACV")

#conter = 0
#while True:
# counter + = 1 #, like an infinite loop

# 1 'to enter a password, log in'.

counter = 0
the while counter <3:
yonghuming = the iNPUT ( "account: ")
password = iNPUT (" password: ")
IF yonghuming ==" Leng "and password ==" 520. ":
Print (" Welcome to: ")
BREAK
the else:
Print (" lose one more: ")
counter + =. 1

counter. 3 == IF:
jixu = INPUT ( "you continue [Y / n-]")
IF jixu == "Y":
0 = counter
the else:
Print ( "entered too many times.")

Guess you like

Origin www.cnblogs.com/Black-sail/p/11546626.html