; Outputs the fibonnaci sequence

start:
    LDI 0 ; Useless on real GDBC as accumulator is cleared on reset
    STA last
    LDI 1
    STA now

loop:
    ; Print sequence value (in now)
    OUT

    ; next = last + now
    ADD last
    JPC end ; Reset if next > 255
    STA next

    ; last = now
    LDA now
    STA last

    ; now = next
    LDA next
    STA now

    JMP loop

end:
    HLT

last: .data 1 0
now:  .data 1 0
next: .data 1 0