The syntax for passing an array to a function is: returnType functionName(dataType arrayName [arraySize]) { // code } Let's see an example, int total(int marks [5]) { // code } Here, we have passed an int type array named marks to the function total (). I have a large switch statement, with special case code for most of the cases. B and for passing an array as a parameter we need to mention empty brackets [] and we should not give any size. It is inefficient to copy the array data in terms of both memory and time; and most of the time, when we pass an array our intention is to just refer to the array we are interested in, not to create a copy of the array. Inside the function, the address is used to access the actual argument used in the call. Pointer 4) Like normal pointers, we can have an array of function pointers. We can pass arguments to the function while calling. Initialize function pointer by storing reference of a function. Array of Function Pointers? - social.msdn.microsoft.com For z/OS® XL C/C++ , use the __cdecl keyword to declare a pointer to a function as a C linkage. Array of function pointers Directly Executing Chunks Of Memory: Function Pointers In C How to pass function pointer as parameter to function. c - How to define an array of function pointers and the functions … Imagine the usefulness of a linked list of function pointers, used for implementing callbacks for example, or a tree of function pointers and values used to hold an algebraic expression; the possibilities are nearly endless . Array It can to be … 1. Function Pointers This can be done in exactly the same way as we pass variables to a function. The idea of the function pointer is to decide at run time what function to call based on runtime coinditions. Why Does C Treat Array Parameters as Pointers? - GeeksforGeeks The above example explains basic working of a function pointer. This function will be called automatically a couple hundred times, I can't change the declaration.