hi, I think this should work find;
void main ()
{
int arr[4][5], row = 4, col = 5;
....
print_array (arr, row, col);
}
void print_array(int arr[][5], int row, int col)
{
for (int x = 0; x < row; x++){
for (int y = 0; y < col; y++)
printf ("%d ", arr[x][y])...
you may use char * as the data type for passing in returning a string, example:
char* func (char * a)
{
char b[5] = "halo";
//codes are here
return b;
}
Andrew Lim
Trying and exploring is adventuring
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.