用户:
你号码是123查看:0 回复:0 评论:0 创建时间:2021-05-29T12:57:37
【作品展示】

【作品介绍】
无
【作品源代码】
import easygui
import turtle
easygui.ynbox('Whether to start asking questions?', 'Do you understand me', ('Yes', 'OK'))
ms = turtle.Screen()
ms = turtle.Screen()
ms.setup(1000, 400)
ms.bgpic("bg2.gif")
easygui.msgbox('There are two versions of the game, one in Chinese and one in English. If you can't read English, you can play Chinese. Or we could play in English. Choose the version you like.', 'Version issues')
p = turtle.Pen()
ms.addshape("one mao.gif")
p.shape("one mao.gif")
p.penup()
p.goto(-300, 40)
question = ["Do I like MC or MN?1.MC 2.MN",
"What's my least fayorite subject?1.Sports 2.Languages",
"Which Star do I like?1.Lu Han 2.Li Cheng",
"I prefer Chinese or five strokes?1.five strokes 2.Chinese",
"Do I use IQIYI or speedy?1.IQIYI 2.speedy"]
answer = [2, 1, 1, 2, 1]
percent = 0
while len(question) > 0:
qus = question.pop(0)
ans = answer.pop(0)
num = ms.numinput("Do you understand me?", qus)
if num == ans:
p.forward(100)
percent += 20
z = turtle.Pen()
z.penup()
z.hideturtle()
z.goto(p.xcor(), 120)
z.pendown()
z.write(f"How well do you know me{percent}%", font=("黑体", 30, "bold"), align="center")
turtle.done()
【提示】
部分含有Python第三方库相关内容的作品,在海龟编辑器网页端无法运行哦!如遇到这种情况,可以打开下面的链接,下载海龟编辑器客户端:
https://python.codemao.cn