diff options
Diffstat (limited to 'Homework6')
| -rw-r--r-- | Homework6/Contacts.h | 2 | ||||
| -rw-r--r-- | Homework6/program.cpp | 7 |
2 files changed, 8 insertions, 1 deletions
diff --git a/Homework6/Contacts.h b/Homework6/Contacts.h index 7aded7d..8e590a0 100644 --- a/Homework6/Contacts.h +++ b/Homework6/Contacts.h @@ -16,6 +16,6 @@ Contact ContactUpdate(); void PrintContacts(Contact(&contacts)[10]); void ContactUpdate(Contact(&contacts)[10]); - +void addContact(Contact(&contacts)[3]); #endif // !CONTACT_H diff --git a/Homework6/program.cpp b/Homework6/program.cpp index c08993f..3704aa9 100644 --- a/Homework6/program.cpp +++ b/Homework6/program.cpp @@ -46,5 +46,12 @@ int main() } while (c != 'x'); + new Contact(); + for (size_t i = 0; i < size; ++i) { + newContacts[i] = contacts[i]; + } + + delete[] contacts; + return 0; }
\ No newline at end of file |