myNumber = 7 while True: guess = int(input('猜猜这个数字是什么')) if guess > myNumber: input('这个数字大了') elif guess < myNumber: input('这个数字小了') else: print('猜对了') break
import turtle turtle.fillcolor('red') turtle.begin_fill() turtle.circle(50) turtle.end_fill() turtle.up() turtle.goto(0,-50) turtle.down() turtle.fillcolor('yellow') turtle.begin_fill() turtle.circle(100) turtle.end_fill() turtle.up() turtle.goto(0,-100) turtle.down() turtle.circle(150) turtle.done()