Task: Implement an Efficient Bidirectional Map (Bimap) in C++
Task: Implement an Efficient Bidirectional Map (Bimap) in C++: a task in Terminal-Lego-15k (Harbor dataset). A bidirectional map (bimap) is a data structure that maintains a one-to-one mapping between two sets of values, allowing efficient lookup in both directions. A naive implementation using…
The task
A bidirectional map (bimap) is a data structure that maintains a one-to-one mapping between two sets of values, allowing efficient lookup in both directions. A naive implementation using two `std::map` instances duplicates all data, using twice the memory.
Part of PrimeIntellect/Terminal-Lego-15k.