Question: Write a program in C++ that will take information in from a file and return and manipulate the data. Use a do while loop to

Write a program in C++ that will take information in from a file and return and manipulate the data.

Use a do while loop to continuously show a menu with four different options

Option 1 will ask the user for a file and read in the file that they specify.

The file that you read in will mirror the example format shown below

---------------------------

Enterprise 94786

2012 Toyota Camry 16.0 120.36 {gps} 1

2014 Honda Civic 28.3 89.54 {camera lidar} 0 Mitch

2006 Ford Fiesta 14.3 78.23 {} 0 Mary

2013 Ford Explorer 21 94.56 {camera lidar radar} 1

2009 Dodge Viper 20.1 78.4 {lidar} 0 Phil

---------------------------

The first line of the file will be the car agency name and zip code

the rest of the lines show the data of each individual car

the following data is given for each car: car year, car make, car model, car tank size, price, {sensors}, availability(0 meaning available 1 meaning unavailable), and lessee

The sensors are within {} and can have 0 up to 3 seperated names

the lessee name will be there only if the car is available

Option 2 will print out the data in the file

Option 3 find and print out the most expensive available car

Option 4 exit the proram

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!