30 Days of Python - Fully Detailed Beginner Guide
Day 1: Print Function
Python ka sabse pehla concept hota hai output dikhana.
print() function screen par output display karta hai.
Jo text quotes ke andar likha hota hai use string kehte hain.
Example:
print("Hello World")
Yeh program screen par Hello World print karega.
print("Welcome to Python")
print("Day 1 Completed")
\n ka use new line ke liye hota hai:
print("Hello\nWorld")
Day 2: Variables
Variable ek container hai jo data store karta hai.
name = "Duck"
age = 17
Yaha name aur age variables hain.
= ko assignment operator kehte hain.
Rules:
- Variable number se start nahi hota
- Space allowed nahi
- Case sensitive hota hai
print(name)
Day 3: Data Types
Main data types:
String: "Hello"
Integer: 10
Float: 5.5
Boolean: True / False
Example:
name = "Duck"
age = 17
height = 5.7
is_student = True
Day 4: User Input
Input lene ke liye input() use hota hai.
name = input("Enter your name: ")
print("Hello", name)
Note: input() hamesha string return karta hai.
Day 5: Type Conversion
Conversion functions:
int()
float()
str()
bool()
Example:
age = int(input("Enter age: "))
print(age + 1)
Day 6: Operators
Arithmetic: + - * /
Comparison: > < == !=
Logical: and or not
Example:
print(5 + 3)
print(10 > 5)
Day 7: If Else
Condition check karne ke liye:
age = 18
if age >= 18:
print("Adult")
else:
print("Minor")
Indentation important hai.
Day 8: For Loop
Repeat code using loop:
for i in range(5):
print(i)
range(5) -> 0 se 4 tak.
Day 9: While Loop
count = 0
while count < 5:
print(count)
count += 1
Day 10: Lists
numbers = [1, 2, 3, 4]
print(numbers[0])
Index 0 se start hota hai.
Day 11: Tuples
Aaj ka topic: Tuples
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Tuples")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 12: Dictionaries
Aaj ka topic: Dictionaries
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Dictionaries")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 13: Sets
Aaj ka topic: Sets
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Sets")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 14: Functions
Aaj ka topic: Functions
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Functions")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 15: Function Arguments
Aaj ka topic: Function Arguments
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Function Arguments")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 16: Return Statement
Aaj ka topic: Return Statement
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Return Statement")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 17: String Methods
Aaj ka topic: String Methods
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning String Methods")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 18: List Methods
Aaj ka topic: List Methods
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning List Methods")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 19: Error Handling
Aaj ka topic: Error Handling
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Error Handling")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 20: File Handling
Aaj ka topic: File Handling
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning File Handling")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 21: Modules
Aaj ka topic: Modules
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Modules")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 22: OOP Basics
Aaj ka topic: OOP Basics
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning OOP Basics")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 23: Classes and Objects
Aaj ka topic: Classes and Objects
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Classes and Objects")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 24: Constructors
Aaj ka topic: Constructors
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Constructors")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 25: Inheritance
Aaj ka topic: Inheritance
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Inheritance")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 26: Mini Project 1
Aaj ka topic: Mini Project 1
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Mini Project 1")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 27: Mini Project 2
Aaj ka topic: Mini Project 2
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Mini Project 2")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 28: Revision Day
Aaj ka topic: Revision Day
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Revision Day")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 29: Practice Problems
Aaj ka topic: Practice Problems
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Practice Problems")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.
Day 30: Final Project
Aaj ka topic: Final Project
Concept samjho + Example dekho + Practice karo.
Example:
print("Learning Final Project")
Steps:
1. Syntax samjho
2. Khud code likho
3. Error aaye toh debug karo
4. Short bana ke explain karo
Consistency is the key.