Question: Lab 0 9 - Sorting a Large Data Set Assume the file called c / temp / WORLDTEMP . TXT holds the ambient temperature (

Lab09- Sorting a "Large" Data Set
Assume the file called c/temp/WORLDTEMP.TXT holds the ambient temperature (simultaneously recorded) of some cities around the globe. A small sample is provided below... .(and many more similar lines followl)
For instance, the temperature in Acapulco was 81 degrees, and in Abidjan, it was 82 degrees.
In this project, our first goal is to read the disk data and store its contents on two parallel vectors called vcity and vtemp. Write a function called makeDatabase to read the disk file and return two parallel vectors listing the cities and their recorded temperatures. The header follows.
Then, you need to sort the dataset so the vectors will appear in asofnding order of temperatures. Please observe that the association between each city and its corresponding temperature must be maintained. Write a function implementing Selection Sort to complete this step (Chapter 8.)
void selectionSort(vector$& vtemp, int count>& vcity, const vector$& vtemp, int count
Lab 0 9 - Sorting a "Large" Data Set Assume the

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 Programming Questions!