Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
garmaine
· 6y ago · 0 comments
std::map in C++ is way easier to work with than std::unordered_map (which didn't even exist until C++11).
Comments
[–]
yuushi
6y ago
Define "way easier". The interface, at least for day to day operations, is basically identical.
[–]
garmaine
OP
6y ago
Supports more features like ordered traversal, generally faster in most cases (yup!), consistent api cost, doesn’t invalidate iterators on certain operations like moving between maps. That’s just off the top of my head.