Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Public | Encapsulation
In-Depth Python OOP

Public

The public access type is a regular access modifier that we used in previous sections.

You should use the public access modifier for attributes/methods that can be used outside the class. Its public information can be used by other tools inside the code.

These attributes/methods are used to get information about the class or manipulate the class in code.

How to define public attribute?

Select the correct answer

Everything was clear?

Section 3. Chapter 2
course content

Course Content

In-Depth Python OOP

Public

The public access type is a regular access modifier that we used in previous sections.

You should use the public access modifier for attributes/methods that can be used outside the class. Its public information can be used by other tools inside the code.

These attributes/methods are used to get information about the class or manipulate the class in code.

How to define public attribute?

Select the correct answer

Everything was clear?

Section 3. Chapter 2
some-alt