Code:#include <iostream> #include <iomanip> #include <cstdlib> using namespace std; int numScores(); float* array(int numscores); void getScores(int numscores,float* array1); void sortArray1(float array1[], int elems); float median( float array1,int numScores); void output1(float array1, float median, int numScores); int main() { int numScores1; float* array1; int median; numScores1= numScores(); array1=array(numScores1); getScores(numScores,array1); sortArray1(array1[],elems); binarySearch(array1, numScores,median1); outputArray(array1,numScores,median1); median(array1,numScores1); output1(array1, median1,numScores); system("pause"); return 0; } int numScores() { int numScores1; do { cout << "Please enter how many scores you have to enter: " << endl; cin >> numScores1; } while (numScores1 > 25 || numScores1 < 5); return numScores1; } float* array(int numScores) { int numScores1; float* array1; array1=new float[numScores1]; if (array1==0) { exit(2); } return array1; } void getScores(int numScores,float* array1) { int i; int numScores1; for (int i=0;i<numScores1;i++) { do { cout << " Please enter your 1st score now: " << endl; cin >> array1[i]; } while (array1[i] > 100 && array1[i] < 0); } } void sortArray1(float array1[], int elems) { bool swap; float temp; do { swap = false; for (int count = 0; count < (elems - 1); count++) { if (array1[count] > array1[count + 1]) { temp = array1[count]; array1[count] = array1[count + 1]; array1[count + 1] = temp; swap = true; } } } while (swap); } float median1( float array1,int numScores) { float median; int numScores1; if (numScores1 %2 !=0) { median = (sortArray1[numScores1/2]+ sortArray1[numScores1]/2-1])/2); } else { median = (sortArray1[numScores1/2]); } return median; } void output1(float array1, float median, int numScores) { int median; cout <<"Median score is " << median << endl; }