Effects: If size() < sz, appends sz - size() value-initialized elements to the sequence. If sz <= size(), equivalent to
list<T>::iterator it = begin(); advance(it, sz); erase(it, end());
Requires: T shall be DefaultConstructible.
void resize(size_type sz, const T& c);
Effects:
if (sz > size())
insert(end(), sz-size(), c);
else if (sz < size()) {
iterator i = begin();
advance(i, sz);
erase(i, end());
}
else
; // do nothing
Requires: T shall be CopyInsertable into *this.