fork download
  1. # Get input from the user
  2. num = int(input("Enter a number: "))
  3.  
  4. # Check the number
  5. if num > 0:
  6. print("The number is positive.")
  7. elif num < 0:
  8. print("The number is negative.")
  9. else:
  10. print("The number is zero.")
  11.  
Success #stdin #stdout 0.01s 7328KB
stdin
45
stdout
Enter a number: The number is positive.