Question: The name of the C+ file must be sortNames.cpp Write a program that will read names from the file names dat. The names read from

 The name of the C+ file must be sortNames.cpp Write aprogram that will read names from the file "names dat". The names

The name of the C+ file must be sortNames.cpp Write a program that will read names from the file "names dat". The names read from the file should be stored into a string array of size 20. The program must use the insertion sort algorithm to sort the array of strings. main will first display the unsorted names, call the sorting function, and then display the sorted array Hint: You will need to use getlinemember function to read names from file into the string array (i.e. getline (inputFile, array[index])

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!