0% found this document useful (0 votes)
67 views6 pages

15 Day Python Core Plan

The document outlines a 15-day Python mastery plan covering essential topics such as syntax, data types, functions, and object-oriented programming. Each day includes theoretical concepts, examples, and practical exercises to reinforce learning. The final day focuses on revision and applying knowledge through coding problems and a mini project.

Uploaded by

Tannu Priya
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
67 views6 pages

15 Day Python Core Plan

The document outlines a 15-day Python mastery plan covering essential topics such as syntax, data types, functions, and object-oriented programming. Each day includes theoretical concepts, examples, and practical exercises to reinforce learning. The final day focuses on revision and applying knowledge through coding problems and a mini project.

Uploaded by

Tannu Priya
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

✅ 15-Day Python Core Mastery Plan (Theory + Examples + Code)

✅ Day 1: Syntax, Variables, Comments

Theory:

• Syntax: Python uses indentation instead of braces.


• Variables: Store data in memory.
• Comments: Use # for single-line, '''...''' or """...""" for multi-line.

Examples:

# Single-line comment
x = 10 # This is a variable
print("Hello, World!")

✅ Day 2: Data Types & Type Casting

Theory:

• int, float, str, bool, list, tuple, dict, set


• Type Casting: Converting between types using int() , float() , str()

Examples:

a = int("5") # Type casting from str to int


b = float(10)
c = str(100)

✅ Day 3: Strings

Theory:

• Strings are sequences of characters


• Use indexing s[0] , slicing s[1:4] , methods s.upper()

Example:

1
s = "Python"
print(s[0:3]) # Output: Pyt
print(s.upper())

✅ Day 4: Lists & Tuples

Theory:

• List: Mutable, ordered ( [] )


• Tuple: Immutable, ordered ( () )

Example:

fruits = ["apple", "banana"]


fruits.append("mango")
colors = ("red", "green")

✅ Day 5: Dictionaries & Sets

Theory:

• Dict: Key-value pairs


• Set: Unordered, no duplicates

Example:

student = {"name": "John", "age": 21}


student["grade"] = "A"
my_set = {1, 2, 3}

✅ Day 6: Conditional Statements

Theory:

• if , elif , else for branching

Example:

2
marks = 85
if marks >= 90:
print("A grade")
elif marks >= 75:
print("B grade")
else:
print("C grade")

✅ Day 7: Loops

Theory:

• for loop, while loop


• break , continue

Example:

for i in range(5):
print(i)

x = 0
while x < 3:
print(x)
x += 1

✅ Day 8: Functions

Theory:

• Define using def , return values, use *args , **kwargs

Example:

def greet(name):
return "Hello, " + name
print(greet("Tannu"))

3
✅ Day 9: Recursion + Lambda

Theory:

• Recursion: A function calling itself


• Lambda: Anonymous function

Example:

def fact(n):
return 1 if n == 0 else n * fact(n-1)

square = lambda x: x**2

✅ Day 10: List Comprehension

Theory:

• Compact syntax to create lists

Example:

even = [x for x in range(10) if x % 2 == 0]

✅ Day 11: File I/O

Theory:

• open() , read() , write() , with statement

Example:

with open("file.txt", "w") as f:


f.write("Hello")

✅ Day 12: Exception Handling

Theory:

• Use try , except , finally , raise

4
Example:

try:
x = 1 / 0
except ZeroDivisionError:
print("Cannot divide by zero")

✅ Day 13: OOP - Classes & Objects

Theory:

• Define class using class , use __init__ , self , methods

Example:

class Car:
def __init__(self, brand):
self.brand = brand
def show(self):
print(self.brand)

✅ Day 14: Inheritance

Theory:

• Inherit parent class using class Child(Parent)


• Use super()

Example:

class A:
def greet(self):
print("Hello")
class B(A):
def greet_b(self):
super().greet()
print("Welcome")

5
✅ Day 15: Revision + Mock Test

• Revise all concepts


• Solve 20 coding problems
• Build a mini project (like Contact Book, BMI calculator, Todo App)

Let me know if you want 40+ questions per topic, MCQs, or a PDF version!

You might also like