GotchiCode needs JavaScript for the code editor and live challenges. Please enable it to play.
GotchiCode
Paths
Courses
Community
Arcade
Leaderboard
◂
Learn OOP in Python
▾
Why Objects?
0/3
State + Behavior
15 XP
Objects Guard Their Rules
15 XP
Each Object Its Own World
15 XP
▾
Attributes
0/4
Instance Attributes
15 XP
Class Attributes
20 XP
A Shared Counter
20 XP
Shadowing
20 XP
▾
Encapsulation
0/4
Private by Convention
20 XP
Properties: Computed Reads
20 XP
Setters: Guarded Writes
25 XP
Reject Bad Values
25 XP
▾
Constructors & Class Methods
0/3
Alternate Constructors
20 XP
From a Dict
20 XP
Static Methods
20 XP
▾
Inheritance
0/4
Subclassing
20 XP
Overriding
20 XP
super().__init__
25 XP
Extending, Not Replacing
25 XP
▾
Polymorphism
0/4
One Loop, Many Kinds
20 XP
Duck Typing
20 XP
Replacing if-chains
25 XP
Fix the Type Chain
25 XP
▾
Abstraction
0/3
Abstract Base Classes
25 XP
The Contract Enforced
25 XP
Shared Code + Abstract Holes
25 XP
▾
Composition
0/3
Has-A, Not Is-A
20 XP
Delegation
25 XP
An Object of Objects
25 XP
▾
Dunder Methods
0/4
__str__ and __repr__
20 XP
__eq__: Meaningful Equality
25 XP
__lt__: Sortable Objects
25 XP
__len__ and __add__
25 XP
▾
Mixins & MRO
0/4
Multiple Parents
25 XP
Method Resolution Order
25 XP
The Mixin Pattern
25 XP
Stacking Mixins
25 XP
▾
Design Habits
0/4
One Class, One Job
25 XP
Tell, Don't Ask
25 XP
Prefer Composition
25 XP
Depend on Little
25 XP
▾
Capstone: Den Keeper
0/4
Capstone: The Creature
30 XP
Capstone: The Specialists
30 XP
Capstone: The Den
30 XP
Capstone: The Sanctuary
30 XP
▾
The Keeper's Workshop
0/3
A Roster You Can Index
20 XP
Walking the Pens
25 XP
The Dusk Lock
30 XP
Loading lesson…