Commit bb37f30b by BellCodeEditor

save project

parent 1e33ec10
Showing with 12 additions and 9 deletions
import turtle import random
pen=turtle.Pen() player=input("请选择:火,水,木")
pen.fillcolor("green") print("我"+player)
pen.begin_fill() list=["火","水","木"]
for i in range(36): computer=random.choice(list)
pen.forward(200) print(computer)
pen.right(170) if player==computer:
pen.end_fill() print("平")
turtle.done() elif(player=="火" and computer=="木") or (player=="木" and computer=="水") or(player=="水" and computer=="火"):
print("赢")
else:
print("输")
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment