mirror of
https://github.com/python/cpython.git
synced 2025-12-15 21:44:50 +00:00
The usual
This commit is contained in:
parent
330c660f66
commit
0b23348aa9
15 changed files with 782 additions and 124 deletions
|
|
@ -26,3 +26,8 @@ class UserDict:
|
|||
else:
|
||||
for k, v in other.items():
|
||||
self.data[k] = v
|
||||
def get(self, key, failobj=None):
|
||||
if self.data.has_key(key):
|
||||
return self.data[key]
|
||||
else:
|
||||
return failobj
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue