Question: I need help entering and correcting the bugs (errors) in this program. 1 //Lab9-2. cpp - displays two monthly car payments 2 //Created/revised by on

I need help entering and correcting the bugs (errors) in this program.

I need help entering and correcting the bugs (errors) in this program.1 //Lab9-2. cpp - displays two monthly car payments 2 //Created/revised by

1 //Lab9-2. cpp - displays two monthly car payments 2 //Created/revised by on 4 #include 5 #include 6 #include 7 using namespace std; 8 9 / /function prototype the names 10 double getPayment (int, double, int); of the formal parameters are 11 not required 12 int main() 13 { 14 int carPrice = 0; 15 int rebate = 0; 16 double creditRate = 0.0; 17 double dealerRate = 0.0; 18 int term = 0; 19 double creditPayment = 0.0; 20 double dealerPayment = 0.0; 21 22 cout > carPrice; 24 cout > rebate; 26 cout > creditRate; 28 cout > dealerRate; 30 cout > term; 32 33 //call function to calculate payments 34 creditPayment = getPayment (carPrice - rebate, 35 creditRate / 12, term * 12); 36 dealerPayment = getPayment (carPrice, 37 dealerRate / 12, term * 12); 38 39 //display payments 40 cout

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 Programming Questions!