An entire array is never passed into a function, only its address. So you can either pass that as a pointer or declare the function like this -
int GetChar (int NumChar, int MaxNumChar [NumChar])
which is pretty much the same as passing in an int *.
int GetChar (int NumChar, int MaxNumChar )
To pass the array, all you have to do is -
referring to the name of an array without using square brackets returns the address of the array or better the address of the first element, which is equivalent to &myArry.
You cant return an array from a function either. Only its pointer. However, since arrays are passed using a pointer whatever changes you make inside the function will be made to the original array as well.
how do I return the characters read in this function back to main?