A function to breed keys of the dict-like object
Project description
# pip install multdict
# >>> from multdict import multdict
>>> idict = {'a': ['x'], 'b': 0}
>>> assert multdict(idict, 0) == {}
>>> assert multdict(idict, 1) is idict
>>> odict = multdict(idict, 2)
>>> assert idict == {'a': ['x'], 'b': 0}
>>> assert odict == {'a0': ['x'], 'b0': 0, 'a1': ['x'], 'b1': 0}
>>> assert odict['a0'] is odict['a1']
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
multdict-0.0.5.tar.gz
(933 Bytes
view details)
File details
Details for the file multdict-0.0.5.tar.gz
.
File metadata
- Download URL: multdict-0.0.5.tar.gz
- Upload date:
- Size: 933 Bytes
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
04544baef4f4467f1ca3d1fe3e30f2501c1eb972cb636a693596a44ad52c8f35
|
|
MD5 |
19e16efac0155b824252f4d57831e150
|
|
BLAKE2b-256 |
b8e97e50e1bc2aa341f0403093f4ec6e24bcc800890d7317bbd49e66231e0ac5
|