Hi, I'm currently writing a class Deck which contains objects (or probably pointers to objects) of another class, Card.
I'm wondering if std::list is better than std::vector?
With std::list, I can sort the cards easier using sort(), and move "piles" of Cards from Deck to Deck using splice().
But std::list doesn't have an operator[], do I have to access the elements using pointers/iterators?
But an iterator like someList.begin() doesn't have an operator+, and assigning the someList.begin() to a Card* is not wise (and we cannot), right?
I can't find the right way to go on =\
Many thanks =)
[EDITED]
Ah, I can use the STL algorithm sort() for std::vector too. Still, referring to the other issues, which one is the better container?