#To check the number entered by user is positive or negative
#to accept number from user
n=int(input("enter number:"))
#giving condition to check the number entered by user is positive , negative or zero
if n<0:
print(n,"is negative number")#A negative number is a number that is less than zero.
elif n==0:
print("zero is neither negative or positive") #zero is not positive and is also not negative.
else:
print(n,"is positive number") #A positive number is a number that is bigger than zero.
OUTPUT :
No comments:
Post a Comment