Commit ba49b50e by BellCodeEditor

save project

parent 062682cc
Showing with 18 additions and 14 deletions
import turtle
for i in range(4):
turtle.forward(200)
turtle.left(90)
turtle.penup()
turtle.goto(-40,-10)
turtle.pendown()
pen=turtle.Pen()
pen.write("天王盖地虎\n你个250",font=("times",40,"normal"))
pen.hideturtle()
turtle.done()
\ No newline at end of file
r=float(input('圆的半径:'))
d=r*2
C=3.14*d
s=3.14*r*r
print('圆的直径是:%.2f'%d)
print('圆的周长是:%.3f'%C)
print('圆的面积是:%.1f'%s)
\ No newline at end of file
import turtle
pen=turtle.Pen()
pen.fillcolor("red")
pen.begin_fill()
pen.right(-45)
pen.forward(100)
pen.circle(50,180)
pen.right(90)
pen.circle(50,180)
pen.forward(100)
pen.end_fill()
turtle.done()
\ No newline at end of file
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