PasteRack.org
Paste # 7838
2018-10-30 09:38:52

Forked from paste # 47002.

Fork as a new paste.

Paste viewed 2651 times.


Embed:

dumb thing

  1. #lang racket
  2. (define (xs->image total some-xs foreground background)
  3.   (local [(define (represent x) (if (element? x some-xs) ground) (else barrier))])
  4.   (define (T image n) (if (= n total) image) (else (T (beside image (represent (+ n 1))) (+ n 1))))
  5.   (T (represent 0) 0))

=>

eval:2:0: local: bad syntax

  in: (local ((define (represent x) (if (element? x some-xs)

ground) (else barrier))))