List::~List() { free(); } void List::free() { while(begin() != end()) erase(begin()); }
List& List::operator=(const List& b) { if (this != &b) { free(); copy(b); } return *this; }