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 hashes)