daily pastebin goal
1%
SHARE
TWEET

Untitled

a guest Aug 27th, 2018 86 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. CICLO:
  2.     READ X
  3.     LOAD X
  4.     STORE POS
  5.     LOAD POS
  6.     JLEZ MENOUNO
  7.     SUB# 3
  8.     JLEZ UNO
  9.     ADD# 3
  10.     DIV# 2
  11.     MUL# 2
  12.     SUB POS
  13.     JZ ZERO
  14.     JUMP DISPARI
  15.  
  16. MENOUNO:
  17.     WRITE# -1
  18.     HALT
  19.  
  20. UNO:
  21.     WRITE# 1
  22.     HALT
  23.  
  24. ZERO:
  25.     WRITE# 0
  26.     HALT
  27.  
  28. DISPARI:
  29.     LOAD# 3
  30.     STORE D
  31.     LOAD POS
  32.     DIV# 2
  33.     STORE META
  34.     JUMP FOR
  35.  
  36. FOR:
  37.     LOAD D
  38.     SUB META
  39.     JLEZ VALUTAIF
  40.     WRITE# 1
  41.     HALT
  42.  
  43. VALUTAIF:
  44.    
  45.     LOAD POS
  46.     DIV D
  47.     MUL D
  48.     SUB POS
  49.     JZ SCRIVI
  50.     LOAD D
  51.     ADD# 2
  52.     STORE D
  53.     JUMP FOR
  54.  
  55. SCRIVI:
  56.     WRITE# 0
  57.     HALT
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top