Right now I can only think of just putting a limited number of profiles. Is it possible to make it limitless, letting the user to add as many profiles as he wants?

12-25-2012

grumpy

Look up the standard containers (std::vector, std::list, etc) for ways to manage collections of arbitrary sizes.

Strictly speaking, it is not possible to have no limit on the size. However, standard containers allow sizes up to what is physically and logically possible on the host system (hardware and operating system) i.e. to the limits of memory and other storage. Since all real computers have finite amounts of memory, there is always a limit.

12-25-2012

Meerul264

Thanks. My book is being tricky again, asking me a question that is to be found on the next next next chapter. I thought there's was a trick to do this under current chapter.. thanks again :)

12-26-2012

Elysia

Just a quick note. If you aren't aware of std::array yet (which you probably aren't), then I recommend you at least get familiar with it here.
It has a number of advantages (knowing its size, disallowing you to pass an array of a size to a function that expects a different size, bounds checking [no bounds checking can be a security risk]), so it may be worth knowing about. Just remember that it requires a TR1 or C++11 compiler (Clang, Visual C++, gcc are known supported ones).