Merge commit '9f82c' into relearning

This commit is contained in:
C. Guy Yarvin 2016-09-01 17:55:38 -07:00
commit a71e7120bc
3 changed files with 5 additions and 5 deletions

View File

@ -959,7 +959,7 @@
::
++ glyph
|= idx/@
=< cha.ole
=< cha
%+ reel glyphs
|= {all/tape ole/{cha/char num/@}}
=+ new=(snag (mod idx (lent all)) all)

View File

@ -125,7 +125,7 @@
++ gas
|= b/(list {k/key n/val})
^+ a
q:(roll b |=({{k/key n/val} q/_a} (put(a q) k n)))
(roll b |=({{k/key n/val} q/_a} (put(a q) k n)))
::
++ tap
^- (list {k/key n/val})

View File

@ -380,7 +380,7 @@
++ reel :: right fold
~/ %reel
|* {a/(list) b/_|=({* *} +<+)}
|- ^+ +<+.b
|- ^+ ,.+<+.b
?~ a
+<+.b
(b i.a $(a t.a))
@ -388,7 +388,7 @@
++ roll :: left fold
~/ %roll
|* {a/(list) b/_|=({* *} +<+)}
|- ^+ +<+.b
|- ^+ ,.+<+.b
?~ a
+<+.b
$(a t.a, b b(+<+ (b i.a +<+.b)))
@ -8450,7 +8450,7 @@
=- [a (welp - ?~(c d [[[%rock %tas p.c] q.c] d]))]
=- (~(tap by -))
%. |=(e/(list tank) [%knit ~(ram re %rose [" " `~] e)])
=< ~(run by f:(reel b .))
=< ~(run by (reel b .))
|= {e/{p/term q/term} f/(jar twig tank)}
(~(add ja f) [%rock %tas p.e] [%leaf (trip q.e)])
;~ plug