This commit is contained in:
Auios 2024-02-11 22:54:37 -05:00
parent a8dea7b3db
commit 861820aa49
2 changed files with 12 additions and 0 deletions

7
examples/add1.asm Normal file
View File

@ -0,0 +1,7 @@
; This program adds 1 to register A until it equals 64, then halts.
ldb 1
loop:
add b
cmp 64
jnz loop
hlt

5
examples/double.asm Normal file
View File

@ -0,0 +1,5 @@
; Endlessly doubles A by adding itself to itself.
lda 1
add b
ldb a
jpr loop