Answered step by step
Verified Expert Solution
Link Copied!
Question
1 Approved Answer

Write an application in C++ that calculates the vehicle registration fee. The programs should read the required inputs from a file to calculate the feet.

Write an application in C++ that calculates the vehicle registration fee.
The programs should read the required inputs from a file to calculate the feet. Create a text file for this purpose. Allow the program to read multiple inputs from the file using while loop and eof() function.
The program should out put a breakdown of the registration fee and the total registration fee for each vehicle. Allowed the program to save the output for all vehicles any single text file.
All new cars and SUVs well have a base fee of $100, buses will have the base fee of $200, and trucks will have a base via $500.
Trucks about 12,000 pounds will have a surcharge of 22% added to the base fee. This will make up the new base fee for for the trucks about 12,000 pounds.
Based on vehicle age, based fee will be reduced by 10% for each youre up to a maximum of seven years. There is a 6.5% tax added to the base fee and there is a two dollar additional hwy fund that is added to the fee.
These pictures are what I have done and where I am stuck. Any help is appreciated thank you! image text in transcribed
image text in transcribed
image text in transcribed
C: \CS1351VehicleInput.txt 1 AB54H77HG553DH3838 TOYOTA 2 C745D4S78SSSWERDDF NISSAN 3 WAGGT345ADFGGGS234 ATLANTIC EXPRESS 2013 BUS 4 LKU338NGTH0988377H KENWORTH T800 5 TNNH75RDG8830R6669 FORD CAMRY PATHFINDER 2014 SUV 2008 CAR 2009 TRUCK 20000 2005 CAR FOCUS C:ICS1351Assignment 1e.cpp 1 #include iostream 2 #include string> 3 #include 4 #include 5 #include 6 using namespace std; 7 int main() 9 ifstream inData; 10 inData.open("VehicleInput.txt") 11 string VehicleIdentificationNumber; 12 string c 13 string carModel; 14 string carYear; 15 string carType; 16 string carweight; 17 double DeductionRate; 18 double Deduction; 19 20 double surcharge; 21 arMaker; double basefee; 23 24 25 26 inData > VehicleIdentificationNumber; 27 28 29 30 31 inoata >> carweight; 32 33 Deduction-((2018- carvear) % 10); 34 35 36 inData carMaker; inoata >> carModel; inData >> carYear; inData >> carType; cout

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image
Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Readings In Database Systems

Authors: Michael Stonebraker

2nd Edition

0934613656, 9780934613651

More Books

Students explore these related Databases questions

Question

=+What country does your family come from?

Answered: 3 weeks ago