Python Data Structures and OOP
Master lists, dictionaries, sets, comprehensions, classes, inheritance, and modules — the foundation for every Python framework.
View badge details
About This Course
Level up from writing scripts to building structured programs. This course covers Python's core data structures (lists, tuples, dictionaries, sets), powerful comprehension syntax, and object-oriented programming with classes, inheritance, and composition. You'll also learn to organize code into reusable modules and packages. Each lesson pairs AI-guided teaching with hands-on coding exercises where you build an inventory management system from scratch. Requires Python Fundamentals or equivalent experience. This is Course 2 of 3 in the Python Beginner Track.
Course Curriculum
12 Lessons
Lists and Tuples
List creation, indexing, slicing, methods (append/extend/insert/remove/pop/sort), iteration with for/enumerate/zip, tuples as immutable sequences, tuple unpacking
Lists and Tuples - Lab Exercises
List creation, indexing, slicing, methods (append/extend/insert/remove/pop/sort), iteration with for/enumerate/zip, tuples as immutable sequences, tuple unpacking, when to use which
Dictionaries and Sets
Dict creation, access, methods, iterating dicts, nested dicts, sets for unique collections, set operations, choosing the right data structure
Dictionaries and Sets - Lab Exercises
Dict creation, access with [] and .get(), methods (keys/values/items/update/pop), iterating dicts, nested dicts, sets for unique collections, set operations (union/intersection/difference), choosing the right data structure
List Comprehensions and Generators
List comprehensions with filtering, dict and set comprehensions, generator expressions, yield, lazy evaluation, memory efficiency
List Comprehensions and Generators - Lab Exercises
List comprehensions with filtering, dict comprehensions, set comprehensions, generator expressions with yield, lazy evaluation, memory efficiency, readability guidelines
Classes and Objects
class, init, self, instance attributes, methods, str/repr, @property, class vs instance attributes
Classes and Objects - Lab Exercises
class keyword, init, self, instance attributes, methods, str and repr, @property decorators, class vs instance attributes
Inheritance and Composition
Single inheritance with super(), method overriding, abstract base classes, composition (has-a vs is-a), design guidelines
Inheritance and Composition - Lab Exercises
Single inheritance with super(), method overriding, abstract base classes (ABC/abstractmethod), composition (has-a vs is-a), design guidelines for when to use each
Modules Packages and Imports
Modules as .py files, import/from import/as, name guard, packages with init.py, standard library highlights
Modules Packages and Imports - Lab Exercises
Modules as .py files, import/from import/as, name == main, packages with init.py, standard library highlights (pathlib, json, datetime, collections)