#write a program that reads one integer and checks if the integer is #positive, or negative, or zero #Input x=int(input("enter integer ")) #Solution 1 (we will use nested if/else or nested if statements) print("solution 1") if(x>0): print(x,"is positive") else: if(x<0): print(x,"is negative") else: print(x,"is zero") #Solution 2 (using if/elif/else statement) print("solution 2") if(x>0): print(x,"is positive) elif(x<0): print(x,"is negative") else: print(x,"is zero) #How it works: #x>0 is evaluated #if True, x is positive printed and program proceeds to next statement #after if/elif/else #if x>0 is False, the program evaluates the next condition that listed in #elif portion, in our case x<0. If x<0 is True, then the statements #associated with that are executed, in our case, x is negative will be #printed, and program proceeds to next statement #after if/elif/else #if both statements, x>0 and x<0 are False, program executed else #statement, in our case it prints x is zero and program proceeds to next #statement after if/elif/else