Computer Science, asked by varnika71, 2 months ago


1. Write a program to print one of the words negative, zero, or positive, according to whether variable x is
less than zero, zero, or greater than zero, respectively?​

Answers

Answered by Stereostomer
3

Answer:

x = int(input("Enter Number")

if x>0:

print("greater than zero")

elif x<0:

print("less than zero")

else:

print("zero")

Answered by prakharagrawal6055
1

Answer:

x=float(input("Enter a number:"))

if x==0:

   print("Your number is Zero")

elif x>0:

   print("Your number is greater than Zero")

elif x<0:

   print("Your number is smaller than Zero")

Explanation:

Similar questions