Namespace std is declared ifstream is declared ofstream is declared const max is set to 50; Int ReadData is declared with the following: ifstream& inFile, ofstream& outFile, int pick array, int drop array, int psgr array int dist array int fare array, float toll array void WriteOutputFile is declared with the following: ofstream& outFile, int pick array, int drop array, int psgr array int dist array int fare array, float toll array int counter void PrintTotalsAndSummary is declared with the following: ofstream& out, int totalRecords Main Function is Declared int record counter is set to zero string nameFile is declared ifstream infile is declared ofstream is set to make a output file to a path infile is set to open a file that has been inputed by the user. Display Please Enter the file name with the file extension: enter nameFile if the file is successfully opened record_counter is set to read the data and output it to the output file. the input file would close. end of if if the output file is successfully opened the data from the input file is written into the output file. end of if otherwise Display Trouble Opening File Display** About to EXIT NOW! ** otherwise Display Trouble Opening File Display** About to EXIT NOW! ** return zero End of Main ReadData Functon is declared int counter is set to 0 inFile is getting ready to read. while the file has not been read Look for the following name and age on each side Trip Pass Dist Fare Toll TF CM 1 5 5.43 9.69 0 9.69 1.78 contiune counting until all data has been read. end of while return the counter end of ReadData WriteOutputFile is declared Display "Here is the output file" for loop (For each record that is less than or equal to counter record is counted) Write each record in this format Trip Pass Dist Fare Toll TF CM 1 5 5.43 9.69 0 9.69 1.78 End of For loop End of WriteOutputFile PrintTotalsAndSummary is declared Display to the user Total People Transported: Total Paid: Average Cost Per Person: Display to the file Total People Transported: Total Paid: Average Cost Per Person: End of PrintTotalsAndSummary End of Program.