The output should contain the total miles driven total


a. Create a text file named car.dat containing the following data (without the headings):

1466_2b94a4fc-f11f-4b28-9ebc-c30efde3c5a9.png

b. Write a C++ program that reads the data in the file created in Exercise 8a and displays the car number, miles driven, gallons of gas used, and miles per gallon (mpg) for each car. The output should contain the total miles driven, total gallons of gas used, and average mpg for all cars. These totals should be displayed at the end of the output report.

Request for Solution File

Ask an Expert for Answer!!
Basic Computer Science: The output should contain the total miles driven total
Reference No:- TGS02192137

Expected delivery within 24 Hours