PYTHON PROGRAMS
.
.
.
40 Programming Questions (Ordered by Complexity — Easy to Hard)
🟢 Level 1: Very Easy
-
Print "Hello, World!"
-
Add two numbers
-
Swap two numbers using a third variable
-
Check if a number is even or odd
-
Check if a number is positive, negative or zero
-
Find the largest of two numbers
-
Find the largest of three numbers
-
Check if a year is a leap year
-
Simple calculator using switch case
-
Sum of first N natural numbers using loop
🟡 Level 2: Easy
-
Factorial of a number using loop
-
Reverse a number
-
Check if a number is palindrome
-
Check if a number is Armstrong
-
Generate Fibonacci series up to N terms
-
Count the number of digits in a number
-
Find GCD and LCM of two numbers
-
Display multiplication table of a number
-
Print star pyramid pattern
-
Count digits, vowels and consonants in a string
🟠 Level 3: Moderate
-
Find largest element in an array
-
Linear search in an array
-
Sort an array (Bubble sort or Selection sort)
-
Matrix addition (2D array)
-
Matrix multiplication
-
Reverse a string
-
Check if a string is palindrome
-
Write a function to check prime number
-
Factorial using recursion
-
String concatenation and comparison
🔵 Level 4: Intermediate
-
Swap values using pointers (C) / references (Java/Python)
-
Structure to store and display student details (C)
-
Create a class for employee with methods (Java/Python OOP)
-
Use constructor and destructor (Java/Python)
-
Demonstrate inheritance with base and derived class (Java/Python)
-
File handling – write data to a file
-
File handling – read data from a file and count characters
-
Menu-driven program using functions (Calculator)
-
Create a basic stack using array
-
Program to find frequency of elements in an array
Comments
Post a Comment