Permalink
Switch branches/tags
Nothing to show
Find file
Fetching contributors…
Cannot retrieve contributors at this time
executable file 22 lines (19 sloc) 455 Bytes
#!/usr/bin/env eve
set 'true (x y: x)
set 'false (x y: y)
set 'int (int: int succ '0)
set 'zero? (int: (int (x: false) true))
set 'incr (n: (f x: f (n f x)))
set 'add (m n: n incr m)
set 'mul (m n: n (x: add m x) 0)
set 'pow (m n: n (x: mul m x) 1)
set '0 (f x: x)
set '1 (incr 0)
set '2 (incr 1)
set '3 (incr 2)
set '4 (incr 3)
set '5 (incr 4)
set '10 (mul 5 2)
set '100 (pow 10 2)
set '1000 (pow 10 3)
int 1000