Advertisement
EmmettMilligan

American Flag

Mar 5th, 2020
866
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.80 KB | None | 0 0
  1. from graphics import *;
  2.  
  3. window = GraphWin("This Do Be America Doe", 500,500);
  4. window.setBackground("white")
  5.  
  6. r6 = Rectangle(Point(25,25),Point(30,30))
  7. r6.setFill("yellow")
  8. r6.draw(window)
  9.  
  10. pt = Point(300, 200)
  11. rect = Rectangle(Point(30 , 30), pt)
  12. rect.setFill("red")
  13. rect.draw(window)
  14.  
  15. for x in range(0,3):
  16. r5 = Rectangle(Point(30,50+25*x),Point(300,60+25*x))
  17. r5.setFill("white")
  18. r5.draw(window)
  19. for x in range(0,4):
  20. r4 = Rectangle(Point(30,100+25*x),Point(300,110+25*x))
  21. r4.setFill("white")
  22. r4.draw(window)
  23. pt2 = Point(150, 100)
  24. rect2 = Rectangle(Point(30 , 30), pt2)
  25. rect2.setFill("blue")
  26. rect2.draw(window)
  27.  
  28. pt3 = Point(30,450)
  29. rect3 = Rectangle(Point (25 , 30),pt3)
  30. rect3.setFill("black")
  31. rect3.draw(window)
  32. i = 10
  33.  
  34.  
  35. window.getMouse();
  36. window.close();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement