Write a C++ program that reads in two partially filled arrays. One array contains student IDs (with int type) and the other contains GPAs (with double type). The program will sort the two arrays according to the student ID and print out the results.
Jump to Post
Use a std::map<int,double> that maps the student id to their GPA. It will be sorted for you. The implementation I leave to you. Note that you got 2 down-votes, mostly because WE DO NOT DO YOUR HOMEWORK FOR YOU! Make an effort to solve the problem. Post the code and …
All 3 Replies
Be a part of the DaniWeb community
We're a friendly, industry-focused community of 1.21 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.