state

a door is a core with a sample. up produces the same door with its count one higher; value produces the count. arm:core runs an arm, and chains read right to left.

count up three times from the default of 0, and produce the value.

=> |% ++ counter |_ count=@ud ++ up ..up(count +(count)) ++ value count -- --
glossary

=> sets the subject to its head, then evaluates its tail against it.

=>([a=1 b=2] b) is 2.

|% makes a core: a battery of named arms, each written ++ name.

reach an arm back out with =< or arm:core.

=<  a
|%
++  a  5
--

is 5.

|_ makes a door: a core carrying a sample, with many named arms.

~(arm door value) sets the sample, then pulls that arm.

a door is a gate with many named entry points.

=/  d
  |_  n=@
  ++  inc  (add n 1)
  --
~(inc d 4)

is 5.

$= wraps a mold with a face, naming the value it produces.

$=(x @) is the mold x=@.

%= resolves a wing with some faces changed.

=/(a [x=1 y=2] a(x 9)) is [x=9 y=2].

irregular forms:

a(x 9) is %=(a x 9)

$(a b) restarts a loop with a changed to b

.+ increments an atom by one.

.+(4) is 5.

irregular forms:

+(a) is .+(a)