您的位置:首页 > 产品设计 > UI/UE

easy_Gui模块游戏

2020-02-16 23:26 363 查看

import easygui as g
import sys
while 1:
g.msgbox(“嗨,欢迎进入第一个界面的小游戏~~”)
msg=“请问你想学到什么小知识呢”
title=“小游戏互动”
choices=[“棋牌室”,“编程”,“网络安全”,“python”]
choice=g.choicebox(msg,title,choices)
#note that we convert choice to string ,in case
#the user cancelled the choice,and we got none
g.msgbox(“你的选择是:”+str(choice),“结果”)
msg=“你希望重新开始小游戏吗”
title=“请选择”
if g.ccbox(msg,title):
pass
else:
sys.exit(0)

  • 点赞
  • 收藏
  • 分享
  • 文章举报
李昭仪668 发布了2 篇原创文章 · 获赞 0 · 访问量 149 私信 关注
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: