Question: Create a linked list program in C++ ..il AT&T 9:02 AM blackboard.wichita.edu linked list to implement a grocery list. You will ask the user for

Create a linked list program in C++  Create a linked list program in C++ ..il AT&T 9:02 AM

..il AT&T 9:02 AM blackboard.wichita.edu linked list to implement a grocery list. You will ask the user for information and modify the list as the user ndicates. All of the information wil be written to a file. Just as in the first program, you are to check to see if the file exists. If it does, open the file and populate the list. When the program terminates, print the nformation to a file. Call the file "grocerylist., The frst entry in the list is to be the number in the list You will modify the Node class that you wrote in the You will create a structure that contains the main data and the Node class will contain a variable of that structure and the link You will write an crdered link list class that will insert, delete. traverse, and retrieve items from the list. The ist will be ordered on the UPC code. You will not enter duplicate items. If the item already exists, then you need to indicate that to the user and not enter it in the Structure data UPC code number of the item Item description-description of item that must be able to include spaces Quantty-number of item to purchase -Cost-cost per item Aisle-number of aisle at store Node class data Structure-will be a declaration of the structure defined abowe the information of the structure must be private to the class, but can be returned from the dass. -Link- pointer to next item in the list Node class member functions Default constructor Constructor that takes UPC, item, quantity, cost and aisle Mutator function to set next pointer Accessor function to retum next pointer Accessor function to returm UPC code Aocessor function to return complete structure -compare UPC function that will compare a given UPC against the one in the class process data function that will calculate and returm the total cost for this item. Total cost oost NOTE: Total cost will NOT be stored in the structure Linked list class data head pointer- points to frst Node in list tail pointer-points to last Node in list -count-keeps track of number of Nodes in list Linked list class functions Any needed constructors Insert node Delete node Traverse ist Retrieve node Check for empty Reburn number in list Note: This is an ORDERED Ist. It will be ordered by UPC number. Note: Remember that a linked list is created in static automatic memory) and a Node is in dynamic

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!