https://github.com/sushobhit27/bimap
A bidirectional dictionary similar to the boost bimap but in python.
https://github.com/sushobhit27/bimap
bidict bidirectional-dictionary bimap boost
Last synced: 2 months ago
JSON representation
A bidirectional dictionary similar to the boost bimap but in python.
- Host: GitHub
- URL: https://github.com/sushobhit27/bimap
- Owner: sushobhit27
- License: mit
- Created: 2018-07-05T17:38:49.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2018-09-20T12:22:40.000Z (over 7 years ago)
- Last Synced: 2025-12-16T02:16:06.742Z (6 months ago)
- Topics: bidict, bidirectional-dictionary, bimap, boost
- Language: Python
- Homepage:
- Size: 9.77 KB
- Stars: 2
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.rst
- License: LICENSE
Awesome Lists containing this project
README
==========
Bimap
==========
Bimap is a bidirectional dictionary, similar to boost bimap.
------------------------
Usage
------------------------
.. code-block:: python
from bimap import Bimap
bm = Bimap()
bm.left[1] = 'a'
bm.left[2] = 'b'
bm.left[3] = 'c'
assert bm.left[2] == 'b'
assert bm.right['c'] == 3
.. code-block::
------------------------
Installation
------------------------
.. code-block::
pip install bimap