Write a Python graphics program that draws the following
shapes:
• window size: 250 x 250 pixels
with window title with your name
• big circle, 50 pixels radius with
center at (125, 125)
• two green circles, 10 pixels radius;
first one centered at (113, 113) and second centered at (137,
113)
• one red line, from (100, 150) to (150,
150)
Then answer this, what do you see? (make this a comment in your code)
##PLEASE ENTER YOUR NAME IN LINE NO 2 OF THE CODE, IT IS THE TITLE
CODE:
from graphics import *
name = "" ##ENTER YOUR NAME HERE
win = GraphWin(name,250,250)
cir = Circle(Point(125,125),50)
cir.draw(win)
cir1 = Circle(Point(113,113), 10)
cir1.setFill("green")
cir1.draw(win)
cir2 = Circle(Point(137,113), 10)
cir2.setFill("green")
cir2.draw(win)
line = Line(Point(100,150), Point(150, 150))
line.setFill('red')
line.draw(win)
win.getMouse()
##IT IS A FACE WITH GREEN EYES AND RED MOUTH
CODE PREVIEW:
OUTPUT:
Get Answers For Free
Most questions answered within 1 hours.