← All lessons

Lesson 12 of 18 · about 20 minutes

Classes and Objects 🏗️

Classes and Objects 🏗️ A class is a blueprint that bundles data and behaviour together. Each object built from it is an instance. class Rocket: def __init__(self, name, fuel): self.name = name self.fuel = fuel def launch(self): if self.fuel Dunder methods…

This lesson is part of Pythonaut Pro. The full Launchpad track is free forever, so you can start there and come back.

See the free lessons