Abstract Heresies
Unorthodox opinions on computer science and programming.
Wednesday, December 29, 2021
Idle puzzles
›
I've been amusing myself with these little puzzles. They're simple enough you can do them in your head, but I coded them up just ...
Thursday, October 14, 2021
Update October 2021
›
Here's a few things I've been playing with lately. jrm-code-project/utilities has a few utilities that I commonly use. Include...
Monday, August 30, 2021
Tail recursion and fold-left
›
fold-left has this basic recursion: (fold-left f init ()) = init (fold-left f init (a . d)) = (fold-left f (f init a) d) A straightfo...
4 comments:
Friday, August 27, 2021
A Floating-point Problem
›
Here's a 2x2 matrix: [64919121 -159018721] [41869520.5 -102558961] We can multiply it by a 2 element vector like this: (defun mxv (a b...
2 comments:
Wednesday, August 18, 2021
Fold right
›
fold-left takes arguments like this: (fold-left function init list ) and computes * (fold-left (lambda (l r) `(f ,l ,r)) 'init ...
8 comments:
Friday, May 21, 2021
Stupid Y operator tricks
›
Here is the delta function: δ = (lambda (f) (f f)) . Delta takes a function and tail calls that function on itself. What happens if we...
1 comment:
Saturday, May 15, 2021
β-conversion
›
If you have an expression that is an application, and the operator of the application is a lambda expression, then you can β-reduce the ...
‹
›
Home
View web version