Python program to find Positive or Negative

num = float(input("Enter a number: "))
if num >= 0:
   if num == 0:
       print("Zero")
   else:
       print("Positive number")
else:
   print("Negative number")

OUTPUT:

Enter a number: 2
Positive number

Leave a Comment