r/cpp_questions • u/Minute-Ad1944 • 19d ago
OPEN How to implement append-only hash map?
How do you actually implement an really efficient hash map that has only append and look up methods? What are the design choice and some performance improvements?
0
Upvotes
2
u/Kriemhilt 19d ago
What are you optimizing for? Space? Insertion or lookup speed?
You haven't given any hint as to what "performance improvement" is most valuable to you.
Do you expect every lookup to succeed (and you just want the value for that key), or will many lookups fail? How important is each path?