This repository contains my basic Python programs written topic-wise for structured learning and concept clarity.
It focuses on:
- 🧠 Logical thinking
- 📚 Core Python fundamentals
- 💻 Writing clean and readable code
- 🚀 Preparing for advanced topics (DSA, Web, ML)
- Variables & Data Types
- Input / Output
- Type Casting
- if / elif / else
- Nested conditions
- for loop
- while loop
- Pattern programs
- User-defined functions
- Arguments & return values
- Lambda functions
- Lists
- Tuples
- Sets
- Dictionaries
- String methods
- Slicing
- Formatting
- Classes & Objects
- Constructors
- Simple methods
def sum_array(arr):
total = 0
for num in arr:
total += num
return total
numbers = [1, 2, 3, 4, 5]
print("Sum =", sum_array(numbers))