Question: (In C++) Write a program that prompts the user to create a grocery list. A menu provides choices to enter an item and item quantity,

(In C++) Write a program that prompts the user to create a grocery list. A menu provides choices to enter an item and item quantity, to display the list, to search for an item, or to exit the program. The list should maintain a sorted alphabetic order after each addition. Use two parallel vectors to implement this program, one to store the item, and the other to store the number of that item. Modify the sort algorithm of your choice and the binary search algorithm to work with vectors. Remember that when the names vector is sorted, you must adjust the numbers vector accordingly.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!