Containers
Vectors: class vector represents a dynamically resizable array.
- Unlike Java, the C++ class must be provided with a template parameter that describes the element type:
vector<int> a; vector<double> b(10); // initially ten elements
- Like arrays and strings, vectors in C++ do not check for out-of-range index values.