dynamic arrays

for all of you who are familiar with C#, you know there is a class called ArrayList in which is a dynamic array is made that has no set size so you can add as many elements as you need (assuming this doesnt go over the limit of what an ArrayList can hold, which is high enough its usually not a problem)

anyhow i was wondering if there was someway to do the same in C++. from what ive read about dynamic memory so far you still need to have a variable to declare the size, so no matter what the array youre making has a set size. is there anyway to create something similair to an ArrayList so that you can add as many elements as you want without specifying a size?

thank you :)
Last edited on
std::vector.
please elaborate a little :)
The name of the container is "std::vector" there's really not much to elaborate on. Did you want a link? http://www.cplusplus.com/reference/stl/vector/
thank you ;)
Topic archived. No new replies allowed.