8bit-cpu-emulator/examples/arithmetic.asm

10 lines
115 B
NASM

; move imm 10 to register A
mov a, 10
; move imm 5 to register B
mov b, 5
; Add a & B
add a, 2
sub a, 2
; Halt
hlt