/* * File: addressBook.cpp * Purpose: Implementation of the AddressBook class. */ #include "addressBook.h" //add and delete return true on success false on failure bool AddressBook::addContact(Contact &c) { //address book is full if(count >= MAXCONTACTS) { return false; } //put the contact onto the array contacts[count++] = c; return true; } bool AddressBook::deleteContact(std::string name) { int i; //find the doomed contact i = search(name); if(i == -1) return false; //not found, so not deleted //shift array back for(int j=i+1; j