There are five method to construct a sequential container:
1. C<T> c // construct a default container which has type T.
2. C c(c2) // construct a container which is a copy of container c2.
3. C c(b, e) // construct a container which elements is from iterator b to e.
4. C c(n, t) // construct a container which has n elements and all value is t.
5. C c(n) // construct a container which has n elements and has initailelized value.
Item 5 is just for sequentail container.
本文介绍了构造序列容器的五种方法:默认构造、复制构造、迭代器范围构造、指定元素数量及值构造、指定元素数量构造。第五种方法仅适用于序列容器。
9286

被折叠的 条评论
为什么被折叠?



