21+ Python Basic Coding on if else statement

21+ Python Basic Coding on if else statement

  1. Python Program to print maximum among two numbers using if-else.
  2. Python Program to print maximum among three numbers using if-else.
  3. Python Program to check a given number is divisible by 3 or not using if-else.
  4. Python Program to check a given number is divisible by 5 or not using if-else.
  5. Python Program to check a given number is divisible by 11 or not using if-else.
  6. Python Program to check a given number is even or odd using if-else.
  7. Python Program to check whether a year is a leap year or not using if-else.
  8. Python Program to check a given input is a digit or not using if-else.
  9. Python Program to check a given input is an alphabet or not using if-else.
  10. Python Program to check a given input is a digit or alphabet using if-else.
  11. Python Program to check a given number is a positive or negative number using if-else.
  12. Python Program to convert temperature from Celsius to Fahrenheit and Fahrenheit to Celsius using if-else.
  13. Python Program to check whether a character is a vowel or consonant using if-else.
  14. Python Program to check whether a character is a vowel or consonant or special character using if-else.
  15. Python Program to check a given character is uppercase or lowercase using if-else.
  16. Python Program to print weekday for a given input week using if-else.
  17. Python Program to print a number of days for a given input month using if-else.
  18. Python Program to check a triangle is an equilateral, isosceles, or scalene triangle using if-else.
  19. Python Program to check a person is valid for a vote or not using if-else?
  20. Python Program to check Division on the basis of marks obtained by students using if-else. Percentage >= 60% : Division 1, Percentage >= 45% : Division 2, Percentage >= 30% : Division 3, Percentage < 30% : Fail
  21. Python Program to Calculate percentage and grade of students on the basis of marks obtained in 5 subjects Maths, Physics, Chemistry, English and Hindi. Marks of subject is taken as an input: Percentage >= 90% : Grade A, Percentage >= 80% : Grade B, Percentage >= 70% : Grade C, Percentage >= 60% : Grade D, Percentage >= 40% : Grade E, Percentage < 40% : Grade F