okay!! what could be more interesting than geometry in its glory. I will be using turtle with tkinter, you are free to experiment with different values, shapes change drastically for better with a little tinkering ,

  1. from turtle import * 
  2. from random import randint 
  3.  
  4.  
  5. bgcolor('black') 
  6. x = 1 
  7. tracer(0, 0) 
  8. while x < 500: 
  9.  
  10. a = randint(0,255) 
  11. b = randint(0,255)  
  12. c = randint(0,255) 
  13.  
  14. colormode(255)  
  15. pencolor(a,b,c) 
  16. fd(45 + x) 
  17. rt(92) 
  18. x = x+1 
  19. exitonclick() 

Changing value of argument of rt to 100

another variation

fd (40+ x) and rt(60)

setting rt(170)

  1. from turtle import * 
  2. tracer(0,0) 
  3. colors = ['red', 'purple', 'blue', 'green', 'orange'] 
  4. for x in range(300): 
  5. pencolor (colors[x % 5]) 
  6. width(x/15 + 1) 
  7. forward(x+6) 
  8. left(59) 
  9. update() 

width(x/100 +1) and left(92)

left(150)

Note: Second sample code would take a little time to carve the figures, to speed up the process use tracer (0, 0) as in first sample , and update()..

View 7 other answers to this question
About · Careers · Privacy · Terms · Contact · Languages · Your Ad Choices · Press ·
© Quora, Inc. 2025