compudanzas/src/uxn.gmo

35 lines
651 B
Plaintext

# uxn
uxn is a little {forth} machine with 32 instructions.
=> https://wiki.xxiivv.com/site/uxn.html uxn
it uses the {postfix} notation.
our projects and sketches are hosted in the {uxnería}
# tutorial
there's a {uxn tutorial} in the making :)
# common code structures
## loop with a counter
loop with a structure that allows you to easily use the iteration counter:
```
( for i=0; i<7; i++ )
#00
&loop
STHk ( stash but keep counter in the stack to use it )
( do stuff )
( to use the counter again, retrieve/keep it with STHkr )
STHr INC DUP ( retrieve and increment counter )
#07 LTH ( while condition )
,&loop JCN
POP
```