Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- B main
- value DEFW 0 ;
- enterI DEFB "Please enter your integer: ",0
- newline DEFB "\n",0
- error DEFB "\nerror",0
- ALIGN
- main ADR R0, enterI
- SWI 3
- next SWI 1
- SWI 4
- CMP R0, #'0'
- BLT skip
- CMP R0, #'9'
- BGT skip
- ADR R0, value
- SWI 4
- SWI 2
- skip ADR R0, error
- SWI 3
- B next
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement