<p>I'm fairly new to the STL, so I was wondering whether there are any dynamically sortable containers?  At the moment my current thinking is to use a vector in conjunction with the various sort algorithms, but I'm not sure whether there's a more appropriate selection given the (presumably) linear complexity of inserting entries into a sorted vector.</p>

<p>To clarify "dynamically", I am looking for a container that I can modify the sorting order at runtime - e.g. sort it in an ascending order, then later re-sort in a descending order.</p>

```
std::set
```
is basically a sorted container.