Question

Write a C++ program that reads 20 names from a file called
names.dat and stores them in two different arrays. Print unsorted
array then modify the selection sort routine so that it sorts the
20 names in the first array. Count how many comparisons are needed
to sort the 20 names. Print the sorted array contents and the
number of comparisons needed.

Next, sort the second array with the bubblesort routine. Count how
many comparisons are needed to sort the array with bubblesort.
Print the unsorted array and the sorted array as you did previously
along with the number of comparisons needed.

(Note: Can someone write this program in C++ only so that I may run
and compile this program.)