PasteRack.org
Paste # 18933
2024-10-18 13:11:13

Forked from paste # 8953.

Fork as a new paste.

Paste viewed 183 times.


Embed:

Sierpinski

  1. #lang racket  ; A picture
  2. (require 2htdp/image)
  3. (let sierpinski ([n 8])
  4.   (if (zero? n)
  5.     (triangle 2 'solid 'red)
  6.     (let ([t (sierpinski (- n 1))])
  7.       (freeze (above t (beside t t))))))

=>

image