Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import os
- import sys
- import math
- WIDTH = 30
- HEIGHT = 15
- A = 0
- B = 0
- S = [46, 44, 45, 126, 58, 59, 61, 33, 42, 35, 36, 64]
- while True:
- b = [32] * 1760
- z = [0] * 1760
- j = 0
- while j < 6.28:
- i = 0;
- while i < 6.28:
- c = math.sin(i)
- l = math.cos(i)
- f = math.sin(j)
- d = math.cos(j)
- e = math.sin(A)
- g = math.cos(A)
- n = math.sin(B)
- m = math.cos(B)
- h = c * (d + 2)
- q = l * (d + 2)
- t = h * g - f * e
- D = 1 / (h * e + f * g + 5)
- o = int(1000 + WIDTH * D * (q * m - t * n) + 80 * int(HEIGHT * D * (q * n + t * m)))
- if 1760 > o and D > z[o]:
- z[o] = D
- r = c * d
- N = int(8 * ((f * e - r * g) * m - r * e - f * g - l * d * n))
- if N < 0:
- N = 0
- b[o] = S[N]
- i += 0.02
- j += 0.07
- os.system('clear')
- o = 0
- while o < 1761:
- if o % 80 == 0:
- p = chr(10)
- else:
- p = chr(b[o])
- sys.stdout.write(p)
- sys.stdout.flush()
- o += 1
- A += 0.04
- B += 0.02
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement