Zanurkuj w Pythonie/Klasa opakowująca UserDict: Różnice pomiędzy wersjami

Usunięta treść Dodana treść
Piotr (dyskusja | edycje)
m wymaga formatowania
 
Piotr (dyskusja | edycje)
mNie podano opisu zmian
Linia 54:
1 The first difference is that you don't need to import the UserDict module, since dict is a built-in datatype and is always available. The second is that you are inheriting from dict directly, instead of from UserDict.UserDict.
2 The third difference is subtle but important. Because of the way UserDict works internally, it requires you to manually call its __init__ method to properly initialize its internal data structures. dict does not work like this; it is not a wrapper, and it requires no explicit initialization.
 
<noinclude>
{{ProstaNawigacja|
poprzart=Python:Interaktywna powłoka|
poprz=Interaktywna powłoka|
spis=Python|
nastart=Python:Twój pierwszy program|
nast=Twój pierwszy program}}
 
[[Kategoria:Python]]
</noinclude>