The stub of AccountManager::deleteAccount() should look like this:
void AccountManager::deleteAccount(const string& userName) {
}
This method should behave as follows:
- Use myAccounts.find() to get an iterator it pointing to the pair containing userName
and its password.
- If it is different from myAccounts.end():
- Use the myAccounts.erase() method
to remove the (userName, password) pair to which it points.
- Otherwise: