I'm juz wondering how do I send a single value to a 8-parameter function...
void enterdata1(int &row1col2)
{
cout<<"Please enter the number for Row 1-Columm 2"<<endl;
cin>>row1col2;
if(row1col2 != 1 && row1col2 != 2&& row1col2 != 3 && row1col2 != 4)
{
cout<<"Please enter the correct number (Which is between 1-4)"<<endl;
cin>>row1col2;
}
displaydata(row1col2);
}
void displaydata( int &row1col1,int &row1col2,int &row1col3,int &row1col4,int &row2col1,
int &row2col2,int &row2col3,int &row2col4,int &row3col1,int &row3col2,
int &row3col3,int &row3col4,int &row4col1,int &row4col2,int &row4col3,
int &row4col4)
{
cout<<" |-"<<"-"<<"-|-"<<"-"<<"-|-"<<"-"<<"-|-"<<"-"<<"-|"<<endl;
cout<<" | "<<row1col1<<" | "<<row1col2<<" | "<<row1col3<<" | "<<row1col4<<" |"<<endl;
cout<<" |-"<<"-"<<"-|-"<<"-"<<"-|-"<<"-"<<"-|-"<<"-"<<"-|"<<endl;
cout<<" | "<<row2col1<<" | "<<row2col2<<" | "<<row2col3<<" | "<<row2col4<<" |"<<endl;
cout<<" |-"<<"-"<<"-|-"<<"-"<<"-|-"<<"-"<<"-|-"<<"-"<<"-|"<<endl;
cout<<" | "<<row3col1<<" | "<<row3col2<<" | "<<row3col3<<" | "<<row3col4<<" |"<<endl;
cout<<" |-"<<"-"<<"-|-"<<"-"<<"-|-"<<"-"<<"-|-"<<"-"<<"-|"<<endl;
cout<<" | "<<row4col1<<" | "<<row4col2<<" | "<<row4col3<<" | "<<row4col4<<" |"<<endl;
cout<<" |-"<<"-"<<"-|-"<<"-"<<"-|-"<<"-"<<"-|-"<<"-"<<"-|"<<endl;
system("pause");
}
how do i send to the correct variable...since the displaydata has more than one parameter