Representación en Pycharm
Ejecución del programa
Código:
from Tkinter import * tk=Tk() canvas=Canvas(tk,width=500,height=800,bg="White") canvas.pack() canvas.create_arc(100,100,400,400,start=0, extent=180,fill="green",outline="green") canvas.create_oval(175,150,200,175,fill="white",outline="white") canvas.create_oval(300,150,325,175,fill="white",outline="white") canvas.create_oval(100,550,200,450,fill="green",outline="green") canvas.create_polygon(100,260,100,500,150,550,350,550,400,500,400,260,fill="green",outline="green") canvas.create_oval(300,550,400,450,fill="green",outline="green") canvas.create_polygon(160,550,160,625,220,625,220,550,fill="green",outline="green") canvas.create_polygon(280,550,280,625,340,625,340,550,fill="green",outline="green") canvas.create_oval(160,600,220,650,fill="green",outline="green") canvas.create_oval(280,600,340,650,fill="green",outline="green") canvas.create_polygon(30,275,30,450,90,450,90,275,fill="green",outline="green") canvas.create_oval(30,250,90,300,fill="green",outline="green") canvas.create_oval(30,425,90,475,fill="green",outline="green") canvas.create_polygon(410,275,410,450,470,450,470,275,fill="green",outline="green") canvas.create_oval(410,250,470,300,fill="green",outline="green") canvas.create_oval(410,425,470,475,fill="green",outline="green") canvas.create_polygon(160,130, 180,118, 160,88, 140,100,fill="green",outline="green") canvas.create_oval(141,85,163,110,fill="green",outline="green") canvas.create_polygon(335,130, 315,118, 335,88, 355,100,fill="green",outline="green") canvas.create_oval(354,85,332,110,fill="green",outline="green") tk.mainloop()
No hay comentarios:
Publicar un comentario