@@ -564,6 +564,11 @@ the final value of the accumulator.
564(To "slam" means to call a gate and give it a sample/samples. In this instance,
564(To "slam" means to call a gate and give it a sample/samples. In this instance,
565`a` is the list of samples that are given to the gate b.)
565`a` is the list of samples that are given to the gate b.)
567+The initial value of the accumulator is the bunt of `b`'s second argument (`+<+`). This can occasionally produce
568+undesired behavior (see examples). If you need more control over the initial
569+value, try making use of `$_` and `|:`, or perhaps [`+spin`](#spin) or
567#### Accepts
572#### Accepts
569`a` is a list.
574`a` is a list.
@@ -600,6 +605,27 @@ The accumulator, which is a noun.
608+`+mul`'s default sample is 1, so calling `+reel` with `+mul` yields the expected behavior:
613+> (reel `(list @)`~[1 2 3 4] mul)
616+However, if you build a gate that uses `+mul` like so, the sample defaults to 0
617+since that is the bunt of `@`:
619+> (reel `(list @)`~[1 2 3 4] |=([a=@ b=@] (mul a b)))
622+We can fix this with `|:`:
624+> (reel `(list @)`~[1 2 3 4] |:([a=1 b=1] (mul a b)))
605### `++roll`
631### `++roll`
@@ -613,6 +639,11 @@ producing the final value of the accumulator.
613(To "slam" means to call a gate and give it a sample/samples. In this instance,
639(To "slam" means to call a gate and give it a sample/samples. In this instance,
614`a` is the list of samples that are given to the gate b.)
640`a` is the list of samples that are given to the gate b.)
642+The initial value of the accumulator is `b`'s second argument (`+<+`). This can
643+occasionally produce undesired behavior (see examples). If you need more control
644+over the initial value, try making use of `$_` and `|:`, or perhaps
645+[`+spin`](#spin) or [`+spun`](#spun).
616#### Accepts
647#### Accepts
618`a` is a list.
649`a` is a list.
@@ -638,15 +669,35 @@ The accumulator, which is a noun.
638#### Examples
669#### Examples
641− > (roll `(list @)`[1 2 3 4 5 ~] add)
672+> (roll `(list @)`[1 2 3 4 5 ~] add)
644− > (roll `(list @)`[6 3 1 ~] sub)
675+> (roll `(list @)`[6 3 1 ~] sub)
645− ! subtract-underflow
676+! subtract-underflow
679+> (roll `(list @)`[1 3 6 ~] sub)
683+`+mul`'s default sample is 1, so calling `+roll` with `+mul` yields the expected behavior:
648− > (roll `(list @)`[1 3 6 ~] sub)
688+> (roll `(list @)`~[1 2 3 4] mul)
691+However, if you build a gate that uses `+mul` like so, the sample defaults to 0
692+since that is the bunt of `@`:
694+> (roll `(list @)`~[1 2 3 4] |=([a=@ b=@] (mul a b)))
697+We can fix this with `|:`:
699+> (roll `(list @)`~[1 2 3 4] |:([a=1 b=1] (mul a b)))
@@ -1042,7 +1093,7 @@ A list
1045−### `++spin`
1096+### `++spin` {#spin}
1047Gate to list, with state
1098Gate to list, with state
@@ -1107,7 +1158,7 @@ is the continuation of the RNG.
1110−### `++spun`
1161+### `++spun` {#spun}
1112Gate to list, with state
1163Gate to list, with state