#include #include #include "bank.h" #include "account.h" using namespace std; void my_free (Account * acc) { delete acc; // call the destructor first } struct myfreeClass { void operator() (Account * acc) { // overloading operator () delete acc;// call the destructor first } }; // Note usage of generic Algorithm: for_each Bank::~Bank() { myfreeClass anObject; for_each(m_Accounts.begin(), m_Accounts.end(), anObject); m_Accounts.clear(); cout << "~Bank: list's size= " <