Phase 6 - Category 5: Real-World Logic Problems
Solve real-world inspired logic problems.
15 programs · open one, then the next
Start with Password Strength Checker- 01Password Strength CheckerAdvancedCheck password strength based on multiple criteria.Open example →py# Take password password = input("Enter password: ") # Check criteria
- 02Advanced Grade CalculatorAdvancedCalculate grade based on multiple subjects with weights.Open example →py# Take number of subjects n = int(input("Enter number of subjects: ")) # Take marks and weights
- 03BMI Calculator with CategoryIntermediateCalculate BMI and categorize.Open example →py# Take inputs weight = float(input("Enter weight (kg): ")) height = float(input("Enter height (m): "))
- 04Simple Interest CalculatorBeginnerCalculate simple interest and total amount.Open example →py# Take inputs principal = float(input("Enter principal: ")) rate = float(input("Enter rate (%): ")) time = float(input("Enter time (years): "))
- 05Compound Interest CalculatorIntermediateCalculate compound interest.Open example →py# Take inputs principal = float(input("Enter principal: ")) rate = float(input("Enter rate (%): ")) time = float(input("Enter time (years): "))
- 06Temperature ConverterIntermediateConvert between Celsius, Fahrenheit, and Kelvin.Open example →py# Take input temp = float(input("Enter temperature: ")) unit = input("Enter unit (C/F/K): ").upper()
- 07Simple Currency ConverterIntermediateConvert between currencies with exchange rates.Open example →py# Exchange rates (example) rates = { 'USD': 1.0, 'EUR': 0.85,
- 08Age CalculatorIntermediateCalculate age from birth date.Open example →pyfrom datetime import date # Take birth date year = int(input("Enter birth year: "))
- 09Discount CalculatorBeginnerCalculate discount and final price.Open example →py# Take inputs price = float(input("Enter price: ")) discount_percent = float(input("Enter discount (%): "))
- 10Tip CalculatorBeginnerCalculate tip and total bill.Open example →py# Take inputs bill = float(input("Enter bill amount: ")) tip_percent = float(input("Enter tip percentage: ")) people = int(input("Enter number of people: "))
- 11Simple CalculatorBeginnerPerform basic arithmetic operations.Open example →py# Take inputs num1 = float(input("Enter first number: ")) operator = input("Enter operator (+, -, *, /): ") num2 = float(input("Enter second number: "))
- 12Grade SystemBeginnerCalculate grade based on percentage.Open example →py# Take percentage percentage = float(input("Enter percentage: ")) # Determine grade
- 13Password ValidatorBeginnerValidate password strength.Open example →py# Take password password = input("Enter password: ") # Validate
- 14Age CalculatorBeginnerCalculate age from birth year.Open example →py# Take inputs from datetime import datetime birth_year = int(input("Enter birth year: ")) current_year = datetime.now().year
- 15Unit ConverterBeginnerConvert between different units.Open example →py# Take inputs value = float(input("Enter value: ")) from_unit = input("From unit (km/m, kg/g, C/F): ") to_unit = input("To unit (km/m, kg/g, C/F): ")