from math import pi,tan,cos,sin from kandinsky import fill_rect,set_pixel from random import randint fill_rect(0,0,320,222,(0,0,0)) for j in range(25): l = -5 + .4 * j k = j * 7 + randint(50,110) c = (k, k, randint(0,200)) for i in range(1440): t = pi * i / 720 r = 20 * (tan(3 * t) + l) if abs(r) < 250: set_pixel(160 + int(r * cos(t)), 110 + int(r * sin(t)),c)