aboutsummaryrefslogtreecommitdiffhomepage
path: root/samples/rosetta/variadic_fixed-point_combinator.bruijn
diff options
context:
space:
mode:
authorMarvin Borner2024-09-13 16:50:26 +0200
committerMarvin Borner2024-09-13 16:50:26 +0200
commitf19998a1416efc2df8fc160cee5da4a58637f749 (patch)
treeb6964047f244503652b7cc09f19a476a5bd271e8 /samples/rosetta/variadic_fixed-point_combinator.bruijn
parent86bf5ed53df9fc9be388352e1609f5b2ea08bcfd (diff)
Added note
Diffstat (limited to 'samples/rosetta/variadic_fixed-point_combinator.bruijn')
-rw-r--r--samples/rosetta/variadic_fixed-point_combinator.bruijn4
1 files changed, 4 insertions, 0 deletions
diff --git a/samples/rosetta/variadic_fixed-point_combinator.bruijn b/samples/rosetta/variadic_fixed-point_combinator.bruijn
index f5d6ec8..f781641 100644
--- a/samples/rosetta/variadic_fixed-point_combinator.bruijn
+++ b/samples/rosetta/variadic_fixed-point_combinator.bruijn
@@ -35,6 +35,7 @@ mod3 ^(explicit-y* (zero : (one : {}two)))
# passes all functions explicitly
# requires a tuple mapping function first
+# or, minified: [[0 0] [[2 (1 1 0) 0]]] (38 bit!)
tupled-y* [y [[2 (1 0) 0]]]
# merged even odd
@@ -55,6 +56,9 @@ mod3 tupled-y* map [0 zero one two] [[[2]]]
:test ((mod3 (+5)) =? (+2)) ([[1]])
+# NOTE: You can merge the mapping argument directly into the list
+# like [[0 (1 A) (1 B) (1 C) ...]]. Then y*=y.
+
# ---------------
# implicit Church
# ---------------