Encapsulation in Python

Muthu
how-to-program
Published in
Jan 1, 2022

Encapsulation = wrapping the data

The OOPs the usage of encapsulation is very normal and easy. It is important to access the value of the variable through the function.

In the following simple example, we can get the value of name using get_name() function.

Some real time example like the following can explain the real importance of the encapsulation.

--

--

Muthu
Muthu

Written by Muthu

» 9+ years of experience in Data engineering, Dashboard designing » 3+ years of experience in Web application development

No responses yet