Back to Freecodecamp

Classes and Objects

curriculum/challenges/english/blocks/object-oriented-programming-with-python/classes-objects-video.md

latest459 B
Original Source

--description--

In this video, you will learn how to create classes and objects in Python to write object-oriented programs.

--questions--

--text--

What is the role of def __init__(self): inside of a class?

--answers--

It represents a function for calling the method.


It specifies the type of the class.


It allows a class to inherit methods from another class.


It represents an initializer method.

--video-solution--

4