Welcome to the phone book editor! Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 4 There is nothing to delete. Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 7 No entries are in memory. Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 1 Enter name of file to read: pb2.txt Can not open pb2.txt! Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 1 Enter name of file to read: pb1.txt Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 3 Enter name: Woody Harrelson Enter e-mail: woody@cheers.bar Enter number: 1-917-555-5432 Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 3 Enter name: Anthony Edwards Enter e-mail: doctor@er.tv Enter number: 111-222-3333 Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 3 Enter name: Robert Duvall Enter e-mail: Boo@first_role.com Enter number: 999-8888 Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 7 Entry #1: Name: Anthony Edwards Email: doctor@er.tv Number: 111-222-3333 Entry #2: Name: Bruce Willis Email: bwillis20@diehard.com Number: 212-555-9090 Entry #3: Name: Diane Keaton Email: Diane@anniehall.edu Number: 999-111-5040 Entry #4: Name: Dustin Hoffman Email: dhoff59@rainmain.com Number: 1-917-555-5554 Entry #5: Name: Emma Thompson Email: emma@emma.com Number: 1-444-432-1288 Entry #6: Name: Harris Ford Email: HarrisonFord@Indy.net Number: 111-222-1090 Entry #7: Name: Martin Scorsese Email: Scorsese@goodfellas.net Number: 1-212-555-1111 Entry #8: Name: Robert DeNiro Email: Bobby@iamcool.org Number: 1-432-555-9911 Entry #9: Name: Robert Duvall Email: Boo@first_role.com Number: 999-8888 Entry #10: Name: Woody Allen Email: Woddy@woody.org Number: 555-9090 Entry #11: Name: Woody Harrelson Email: woody@cheers.bar Number: 1-917-555-5432 Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 6 Enter string to search for: Rob Entry #8: Name: Robert DeNiro Email: Bobby@iamcool.org Number: 1-432-555-9911 Entry #9: Name: Robert Duvall Email: Boo@first_role.com Number: 999-8888 Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 6 Enter string to search for: Woody Entry #10: Name: Woody Allen Email: Woddy@woody.org Number: 555-9090 Entry #11: Name: Woody Harrelson Email: woody@cheers.bar Number: 1-917-555-5432 Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 4 Enter entry number to delete: 1 Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 4 Enter entry number to delete: 7 Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 4 Enter entry number to delete: 7 Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 2 Enter name of file to create: pb2.txt Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 5 All entries have been deleted. Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 7 No entries are in memory. Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 3 Enter name: John Doe Enter e-mail: johndoe954@hotmail.com Enter number: 555-5555 Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 7 Entry #1: Name: John Doe Email: johndoe954@hotmail.com Number: 555-5555 Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 4 Enter entry number to delete: 1 Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 7 No entries are in memory. Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 1 Enter name of file to read: pb2.txt Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 1 You can't read a phone book when one is in memory. Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 7 Entry #1: Name: Bruce Willis Email: bwillis20@diehard.com Number: 212-555-9090 Entry #2: Name: Diane Keaton Email: Diane@anniehall.edu Number: 999-111-5040 Entry #3: Name: Dustin Hoffman Email: dhoff59@rainmain.com Number: 1-917-555-5554 Entry #4: Name: Emma Thompson Email: emma@emma.com Number: 1-444-432-1288 Entry #5: Name: Harris Ford Email: HarrisonFord@Indy.net Number: 111-222-1090 Entry #6: Name: Martin Scorsese Email: Scorsese@goodfellas.net Number: 1-212-555-1111 Entry #7: Name: Woody Allen Email: Woddy@woody.org Number: 555-9090 Entry #8: Name: Woody Harrelson Email: woody@cheers.bar Number: 1-917-555-5432 Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 999 That is not an option. Please try again. Main Menu: (1) Read a phone book file. (2) Save current phone book in a file. (3) Add an entry. (4) Delete an entry. (5) Delete all entries. (6) Search current entries. (7) Display all entries. (8) Quit. Enter selection: 8 Goodbye!