Why does it output 0-5 and not the selected partNumbers? What is wrong?
Code:
void process(double partPrice[ELEMENT][PRICE], string partNames[NAME])
{
int j = 0;
const int size = 5;
string custName[size];
string state[size];
for (j=0; j<size; j++)
{
cout << endl;
cout << "Eenter Customer's Name : ";
cin >> custName[j];
stateSearch();
cout << endl;
}
cout << left;
cout << setw(25)<< "Billing Report" << endl;
cout << setw(10)<< "Sugg.";
cout << setw(10)<< "Sales";
cout << setw(10) << "Total" << endl;
cout << setw(15) <<"Name";
cout << setw(10) << "State";
cout << setw(10) << "Cost" ;
cout << setw(10) << "Retail";
cout << setw(10) << "Price";
cout << setw(10) << "Cost";
cout << endl;
for(j=0; j<size; j++)
{
cout << left;
cout << fixed << showpoint<< setprecision(2);
cout << setw(15) << custName[j];
cout << setw(6) << state[j];
cout << setw(10) << partPrice[j][0];
cout << setw(10) << partPrice[j][1];
cout << setw(10) << partPrice[j][2];
cout << endl;
cout << setw(10) << partNames[j];
cout << endl;
}
}