Question: What is wrong with this line of code for C+? It will not launch the program when I try to debug it. #include #include //

What is wrong with this line of code for C+? It will not launch the program when I try to debug it.

#include

#include // std::setbase

using namespace std;

int main()

{

int customerNumber[20],sale[20],n,total=0;

cout<<"How many customer you want to track? ";

cin>>n;

for(int i=0;i

{

cout<<"Enter customer number.";

cin>>customerNumber[i];

cout<<"Enter the sale for the customer ";

cin>>sale[i];

}

cout<<"Sale for customer ";

cout<<"Customer numberCustomer sale ";

for(int i=0;i

{

cout<

total = total + sale[i];

}

cout<<"Total sales are: $"<

cout<<"Average sale per customer is: $"<<(total/n)<<" ";

cout<<"---------------------------------------";

return 0;

}

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!