Python Notes

References:

📌 1. Key Python Topics to Cover

SI
Section
Topics
Done

1

Data types (int, float, str, bool), lists, tuples, sets, dictionaries, type casting, basic operators, comparison operators, and logical operators

2

if-else statements, for loops, while loops, break, continue, pass

3

List, set, and dictionary comprehensions, filtering elements, nested comprehensions

4

Defining functions, return values, *args, **kwargs, lambda functions, recursion, default and keyword arguments

5

Classes, inheritance, encapsulation, polymorphism, class attributes vs instance attributes, init method, @staticmethod, @classmethod, super(), method resolution order (MRO)

6

try-except-finally, raising exceptions (raise), custom exceptions, assertions

7

with open() for file handling, file modes ('r', 'w', 'a', etc.), reading large files efficiently (line by line), file reading techniques, context managers

8

Lists, tuples, sets, dictionaries, Stacks (using lists), Queues (using collections.deque), namedtuple, Counter (from collections), DefaultDict (from collections)

9

One-liners, list comprehensions, use of any(), all(), sorted() with lambda, ternary operators, zip(), efficient looping with zip() and enumerate()

10

Generator vs list (using yield), time and space complexity, memory profiling (memory_profiler module), using functools.lru_cache for caching

11

Writing command-line interface (CLI) scripts, using argparse for argument parsing, os module for file and directory manipulation, subprocess for running shell commands

12

Basic threading, the Global Interpreter Lock (GIL), multiprocessing basics, asynchronous programming with asyncio

13

Function decorators (@decorator_name), class decorators, built-in decorators (e.g., @staticmethod, @classmethod), creating custom decorators, chaining decorators

14

math, collections, itertools, and String Manipulation, Other useful libraries.

15

Iterables vs. Iterators vs. Generators

Last updated