Question: Add the following functionality to the previous lab Menu (use a switch statement) options to change status print all active items print all discontinued items

Add the following functionality to the previous lab

  • Menu (use a switch statement) options to
    • change status
    • print all "active" items
    • print all "discontinued" items
    • print all "recalled" items
    • sort by any field in ascending order
  • Sorting
    • Write one function to sort by any field using a parallel array of pointers
    • Do not copy and paste sort code five times into the same function. Bubble sort is the easiest to modify.
    • sorting using pointers is faster because you have to swap pointers only, which are normally stored in 4 bytes; it also allows you to preserve the original order of the items
    • submenu for sorting options is optional
    • if you create a submenu to sort by various fields, add an option to go back to the main menu without being forced to sort
  • Printing all, active, recalled, and the discontinued items
    • modify the print function created in the previous lab to print recalled and discontinued items as well

Write code in c++

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

To add the specified functionalities to your existing C code it seems like you are implementing a system to manage items with various statuses such as active discontinued and recalled Lets break down ... View full answer

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!