
This course includes our updated coding exercises so you can practice your skills as you learn.
See a demo
Explore using functions in Python to compute monthly profits with a reusable template, preventing repetitive code, and learn function definitions, calls, and parameters for scalable calculations.
Identify parameters inside the function bracket, define a sum that takes two numbers, call the function with arguments, and print their sum.
Discover how a function returns a value instead of printing it, catch result in a variable, and use it in calculations. Returns can be numbers, booleans, or strings, like is_greater.
Create a python function calculator that takes three parameters: number one, number two, and an operator; supports plus, minus, multiplication, and division; guards division by zero and handles invalid operator.
Create a car class as a template to instantiate objects with brand, model, color, and a speed set by the constructor, then start, stop, and drive at a set speed.
Create an object of the car class using the constructor with brand, model, and color. Start the car, set its speed, and drive at a chosen speed.
Learn how to create objects of a car class by specifying attributes or properties such as brand, model, color, and speed, and implement methods that define the car's behaviors.
Create a car owner class with __init__, store name and ic, enable buying a car, and access its brand and color, illustrating object oriented programming with car and owner objects.
Explore how inheritance uses a vehicle superclass to share brand, model, color, and start and stop methods with car and track subclasses, and drive at speed 50.
Override explains how subclasses customize inherited attributes and methods with race and drive on highway examples. It shows using super init and overriding speed limits like 70 vs 80.
Apply Python OOP fundamentals by building a pet hierarchy with a base class pet and subclasses dog and cat, using constructors, inheritance, and method overriding to create and use objects.
Learn how private attributes use double underscores to protect the brand via name mangling, and access them safely with getters and setters that validate values.
Demonstrate private methods in Python OOP with a vehicle class, using a private method calculate_insurance_rating and a public get_insurance_rating, and illustrate access via an attribute error.
Master Python OOP encapsulation by bundling a class's attributes and methods, restricting direct access with private members, and validating inputs such as ensuring brand value contains only letters or numbers.
Refine a pet hierarchy with dog and cat subclasses by making attributes private and adding getters and setters, and validate nonnegative age, alphabetic name, and breed handling.
Explore Python's special methods (dunder methods) using vehicle, car, and truck classes to customize constructors, string representations, and comparisons, like __init__, __str__, and __ge__.
Explore overloading in Python, including len working on strings and lists and the plus operator, while Python lacks method overloading and overwrites earlier definitions.
Master method overriding in inheritance by comparing a superclass and subclass driving on highway, adjusting speeds to 80 and 70, using a protected speed attribute and a get speed method.
Explore polymorphism, defined as there are many forms, with poly meaning many and morphism meaning form. See how overloading and overriding represent different types of polymorphism.
Abstraction uses an abstract base class to prevent instantiating a vehicle and require subclass implementations. Car and truck implement the abstract method, demonstrating ABC in Python and the instantiation error.
Explore composition by showing how a car contains an engine. See how the engine is created inside the vehicle and controlled via private attributes and getters and setters.
Explore aggregation in Python OOP by modeling a garage that has many vehicles without owning them, and manage cars with add, get, and remove operations.
Build a shopping cart system with an abstract product class and concrete clothing and electronics, using cart items, aggregation, and user composition to compute totals and compare carts.
You have built a solid foundation in Python programming and OOP concepts, ready to tackle advanced topics. Share your feedback to help others learn, and explore advanced courses on Udemy.
Want to finally understand Object-Oriented Programming (OOP) in Python? This course makes learning OOP simple, structured, and practical — even if you're completely new to programming or have struggled with OOP before.
Python is one of the most popular programming languages, and mastering OOP is a key skill for writing clean, efficient, and scalable code. This course breaks down complex topics like Classes, Objects, Inheritance, Encapsulation, and Polymorphism into easy-to-follow lessons with real-world examples.
Read what students have said:
You are definitely among the top 3 of courses. Your examples are relatable and you really simplify the terms and concepts for us to grasp and learn easily. thank you
this is one of the best course that i have studied,she makes it look very simple,atleast now i can do something on my own,from beginner to where i am now at,continue with the good work
For more reviews, head over to the course review section.
What you'll learn:
How to create and work with classes and objects in Python
The power of inheritance to reuse and organize code
Understanding and applying polymorphism the easy way
Encapsulation and the concept of public, protected, and private attributes
Practical examples to apply OOP to real-world problems
This course is ideal for:
Beginners with basic Python knowledge
Students preparing for coding interviews or exams
Anyone looking to build clean, reusable, and maintainable code
Worried about your Python basics? No problem! Take my free Python Fundamentals course on Udemy to get up to speed.
By the end of this course, you'll not only understand OOP — you'll be able to apply it confidently in your Python projects.
Start your OOP journey now.