Question: 8.10 Project 4 - Help me Sort My Roster About The class roster program is working really well. However, it would be nice to be

 8.10 Project 4 - Help me Sort My Roster About The
class roster program is working really well. However, it would be nice
to be able to sort students based on first name, last name,
or their grade. I would like a program where I can choose
how my roster is sorted and then print out the class summary

8.10 Project 4 - Help me Sort My Roster About The class roster program is working really well. However, it would be nice to be able to sort students based on first name, last name, or their grade. I would like a program where I can choose how my roster is sorted and then print out the class summary Specification have provided a template main.cpp for you to edit functions which have /*Provide Implementation/ are for you to edit Note: You are not allowed to change any of the function signature (ve, add or edit parameter names and types, or change the function name or its return type) Note: For sorting you must implement a Selection Sort Note: If two elements are equal do not swap the elements SortByFirstName(vector students vector grades) - option Sorts students and grades by the students first name SortByLostName(vector students, vector grades) option (lowercase L) Sorts students and grades by the students last name SortByGrade vector students, vector grades) option Sorts students and grades by the students grade You will also need to add code which culs the functions if the user selecta to sort using that sort by function You can find it in the code by searching for provide toplementation for other menu options/ Unlike part assignments which test matching output this assignment tests output along with testing your functions directly uning unit tests. The unit tests will use your functions with hardcoded vector if the tests fails the unit tests will print out what it expected compared to what your function did when sorting. If you have any question please reach out via email, discussion board, or during office hours main.cpp Lood det forplate 1 #include > nofStudents; 83 ) 84 85 void Printer 86 string neu - Please choose one of the following options" 87 a odd a studenti 88 "e: remove a student 89 p: print the class sumary" 90 ": print menu 91 "f: sort - First namen 92 "1: sort - last namen 93 "O! sort grade 90 "q: quit programin 95 NG cout

123 cout > firstName >> lastName >> grade; 134 students.push_back(firstName"" .lastName); 135 grades.push_backCgrade): 136) 137 void RenoveStudent(vector Estudents, vector double> &grades) { 138 string removeStudent "Please enter students first and last name": 139 string firstName, lastName; 140 141 cout > firstNane >> LastName: 143 string fullNone - firstName + last Nane: 144 for(int i -e; i students.size: 1) 145 if(students.at(t) - fullNone) { 146 students.erase(students.begin() + D): 147 grades.eraseCgrades.begin( + 1). 148 cout

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!