-
Importing modules
-
Object Oriented Programming
-
Benefits and Principles of OOP Design
-
Classes
-
Instances
-
Initializing with attributes using init
-
Instance methods
-
Showing instances using repr
-
Self
-
Stretch Topics: Object properties
-
Stretch Topics: Class attributes and methods
-
Humans initialize with a
first_name
andlast_name
. -
Humans initialize with an
_age
of 0. This will be a property (age
) later. -
Give humans a
__repr__
that adequately shows their characteristics. You decide what this looks like. -
Give humans a method
say_full_name
which returns their concatenatedfirst_name
andlast_name
. -
Give humans a method
happy_birthday
which increments that human's age by 1. -
Give humans a property
age
. When someone attempts to set a human'sage
directly it instead doesn't change and returns the string"Quit lying about your age!"
.