If else statement python program

 num = int(input("Enter the value of num:"))

if (num < 0):

    print("Number is  negative")

elif (num==0):

    print("Number is zero")

elif (num==9999):

    print("Number is special")

else:

    print("Number is positive")

    

print("I am happy now")


result:

Enter the value of num:60

Number is positive

I am happy now

Comments

Popular posts from this blog

According to Data Science Topic-13 Modules

Functions in Python:

According to Data Science Topic-12 If else program examples