why to use weakly private methods when we can access them easily.

Python single underscore methods.

9th Jul 2016, 9:35 AM
jayrajarora2694 - avatar
1 Answer
+ 2
It is to discourage the use of them, not totally block access to them. Private variables and methods are intended for the use of that class only. Accessing them may cause instances of the class to work differently than intended.
9th Jul 2016, 12:24 PM
Gershon Fosu
Gershon Fosu - avatar