哪里有问题

import random as r
import easygui as e
while True:
    lis=['1','2','3','4','5','6','7','8','9']
    caipiao=r.sample(lis,5)
    caipiao=''.join(caipiao)
    answer=e.enterbox("5位数字:")
    sum=0
    if caipiao==answer:
        sum+=10000
        e.msgbox("彩票号:%s 奖金:%d元" %(caipiao,sum)
    else:
        for i in caipiao:
            if i in answer:
                sum+=1000
        e.msgbox(f"彩票号:{caipiao}")
        e.msgbox(f'奖金:{sum}元')
e.msgbox('感谢使用')

上一篇:测量运行1段AutoHotkey脚本代码所需消耗的时间


下一篇:简单Python代码写ASCII解码器