num=int(input("Please enter a number to check Positive Negative or Zero ")) if(num>0): print("Given number is a positive number"); elif(num<0): print("Given number is a negative number"); else: print(" Given number is zero"); Output 1: Please enter a number to check Positive Negative or Zero 12 Given number is a positive number Output 2: Please enter a number to check Positive Negative or Zero -12 Given number is a negative number Output 3: Please enter a number to check Positive Negative or Zero 0 Given number is zero
इन्हें भी देखें।
- while loop
- for loop
- nested loops
- loop control statements (Break, Continue, Pass)
- if statement
- if-else statement
- if-elif statement
- nested if statement
- range() function
- keywords
- Identifiers (names)
- Literals
- Operators
- punctuatorts
Python Programs के लिये यहाँ click करें।