import random
secret = random.randint(1,100)  #计算机生成一个随机数
times = 3
while times :
    n = int(input("请输入数字："))
    if n == secret:
        print("你答对了！")
        break
    elif n >= secret:
        print("你的数字太大了！")
        times = times - 1
    else:
        print("你输入的数字太小了")
        times = times - 1
print("你的次数用完了！")



d38101e4805dd73944b9318b70349804442e7c95
<mask token>

<mask token>
while times:
    n = int(input('请输入数字：'))
    if n == secret:
        print('你答对了！')
        break
    elif n >= secret:
        print('你的数字太大了！')
        times = times - 1
    else:
        print('你输入的数字太小了')
        times = times - 1
print('你的次数用完了！')

<mask token>
secret = random.randint(1, 100)
times = 3
while times:
    n = int(input('请输入数字：'))
    if n == secret:
        print('你答对了！')
        break
    elif n >= secret:
        print('你的数字太大了！')
        times = times - 1
    else:
        print('你输入的数字太小了')
        times = times - 1
print('你的次数用完了！')

import random
secret = random.randint(1, 100)
times = 3
while times:
    n = int(input('请输入数字：'))
    if n == secret:
        print('你答对了！')
        break
    elif n >= secret:
        print('你的数字太大了！')
        times = times - 1
    else:
        print('你输入的数字太小了')
        times = times - 1
print('你的次数用完了！')

import random
secret = random.randint(1,100)  #计算机生成一个随机数
times = 3
while times :
    n = int(input("请输入数字："))
    if n == secret:
        print("你答对了！")
        break
    elif n >= secret:
        print("你的数字太大了！")
        times = times - 1
    else:
        print("你输入的数字太小了")
        times = times - 1
print("你的次数用完了！")


