时间复杂度:
mapunordered_map
Orderingincreasing orderno orderImplementationSelf balancing BSTHash Tablesearch timelog(n) O(1): 平均水ping
O(n):最糟糕情况
Insertion timelog(n) + RebalanceSame sa searchDelete timelog(n) + RebalanceSame sa search
参考资料
1. C++面试常见题目7_STL之map与unordered_map(红黑树VS哈希表) 2. c++ STL容器map和unordered_map有什么区别
转载请注明原文地址: https://yun.8miu.com/read-17337.html