2 ms·
Add: got it working with simh ("brew install simh; pdp1") using the instructions in the linked zip file. It is _really_ delicate, but I finally got fib working
by FullyFunctional 4y ago
Add: got it working with simh ("brew install simh; pdp1") using the instructions in the linked zip file. It is _really_ delicate, but I finally got fib working:
(rplacd (quote sub) (quote (expr (lambda (a b) (plus a (minus b))))))
(rplacd (quote fib) (quote (expr (lambda (l) (cond ((greaterp l 1) (plus (fib (sub l 2)) (fib (sub l 1)))) (t l))))))
(fib 22)
5030
Why yes, it's all in octal fib(18) = 2584