Question: IN C++ Read a file with the following fields: first and last names, GPA, an Id number , and email. ( no need of error

IN C++

Read a file with the following fields: first and last names, GPA, an Id number , and email. ( no need of error checking).

Creat a menu which allows to : print records unsorted,sort by various fields (create one function to sort records by any field using array of pointers), and quit the program.

No goto, continue, break ( except for switch)

I am trying to write this program but im having trouble writing one function that can sort any field from a struct using a pointer pointing to an array. I tried switch but i dont know what im doing wrong. Thank you in advance.

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!