Hacker News new | ask | show | jobs
by merijnv 1466 days ago
std::map (as opposed to std::unordered_map) uses a balanced binary search tree approach and thus guarantees O(log n) lookup for anything that has a well-defined total order (i.e. comparison function), without worrying about hash functions, etc.

So, yes you can ;)