if_elif.alc 222 B

123456789101112131415
  1. include "primitives.alh"
  2. Integer function compare_with_zero(n : Integer):
  3. if(n < 0):
  4. return -1!
  5. elif(n == 0):
  6. return 0!
  7. return 1!
  8. Void function main():
  9. while(True):
  10. output(compare_with_zero(input()))
  11. return!