PRELOADER

不念过去 不负现在 不畏将来

当前文章 : 《guess number 猜数字》

12/4/2018 —— 

一、说明

使用python编写的猜数字游戏

二、python代码

lucky_number = 12
count = 6

while (count>0):

    input_number = (int)(input("please input a number from 0 t 100:"))
    count = count - 1

    if input_number<lucky_number:
        print("the lucky number is bigger")
    elif input_number>lucky_number:
        print("the lucke number is smaller")
    else:
        print("bingo")
        break

else:
    print("you have no chance")