相关疑难解决方法(0)

标准容器的复杂性保证是什么?

显然;-)标准容器提供某种形式的保证.

什么类型的保证以及不同类型的容器之间究竟有什么区别?

从工作的SGI页(约STL)我想出了这一点:

Container Types:
================
Container:
    Forward Container
        Reverse Container
            Random Access Container
    Sequence
        Front Insert Sequence
        Back  Insert Sequence
    Associative Container
        Simple   Associative Container
        Pair     Associative Container
        Sorted   Associative Container
        Multiple Associative Container

Container Types mapped to Standard Containers
=============================================

std::vector:    Sequence    Back        Sequence                    Forward/Reverse/Random Container
std::deque:     Sequence    Front/Back  Sequence                    Forward/Reverse/Random Container
std::list:      Sequence    Front/Back  Sequence                    Forward/Reverse Container
std::set:       Sorted/Simple/Unique    Associative Container       Forward Container
std::map:       Sorted/Pair/Unique      Associative Container       Forward Container
std::multiset:  Sorted/Simple/Multiple  Associative Container …
Run Code Online (Sandbox Code Playgroud)

c++ big-o containers stl

153
推荐指数
2
解决办法
12万
查看次数

标签 统计

big-o ×1

c++ ×1

containers ×1

stl ×1