风-fmgao

导航

guess_age

age_shanshan = 18
count = 3
num = 0
while num < count:
age = int(input("age:"))
if age == age_shanshan:
print("good")
break
else:
print("不对")
num += 1
if num == 3:
choice = input("是否还玩,继续输入Y或者y")
if choice == 'y' or choice == 'Y':
num = 0
print("over")

posted on 2018-05-13 11:51  风-fmgao  阅读(128)  评论(0编辑  收藏  举报