Horje
two underscores python Code Example
two underscores python
>>> class MyClass():
...     def __init__(self):
...             self.__superprivate = "Hello"
...             self._semiprivate = ", world!"
...
>>> mc = MyClass()
>>> print mc.__superprivate
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: myClass instance has no attribute '__superprivate'
>>> print mc._semiprivate
, world!
>>> print mc.__dict__
{'_MyClass__superprivate': 'Hello', '_semiprivate': ', world!'}




Python

Related
what is python -u Code Example what is python -u Code Example
is 2 an even number Code Example is 2 an even number Code Example
configuring tailwindcss, vue and laravel Code Example configuring tailwindcss, vue and laravel Code Example
WebDriverWait Code Example WebDriverWait Code Example
ignore nil rows value in openpyxl Code Example ignore nil rows value in openpyxl Code Example

Type:
Code Example
Category:
Coding
Sub Category:
Code Example
Uploaded by:
Admin
Views:
6