mirror of
https://github.com/lisk77/lambda.git
synced 2025-10-24 02:08:49 +00:00
12 lines
223 B
Text
12 lines
223 B
Text
pair = \ x y z . z x y;
|
|
|
|
first = \ p . p (\ x y . x);
|
|
second = \ p . p (\ x y . y);
|
|
|
|
cons = pair;
|
|
head = first;
|
|
tail = second;
|
|
nil = \ x y . y;
|
|
isNil = \ l . l (\ h t d . (\ x y . y)) (\ x y . x);
|
|
|
|
main = first (pair a b);
|