How to pass a matrix (a function has two dimensions) in a function parameter.
Thank you in advanceCode:for (i = 0; i <100; i + +) ( myFunction (table [i]); )
How to pass a matrix (a function has two dimensions) in a function parameter.
Thank you in advanceCode:for (i = 0; i <100; i + +) ( myFunction (table [i]); )
Then you pass a parameter to your function:Code:int ** tab; / / or else char ** table; / / or else char * table[100];
Code:myFunction (table); / / or else for (i = 0; i <100; i + +) ( myFunction (table [i]); )
The differences between Matrix parameters and Query Parameters are much more than just convention. Objects and class functions are often associated with code, and C structures may seem somewhat arcane, so C libraries are often dismissed as viable solutions.Matrix parameters are not resources, they are aspects that help reference a resource in an information space that is difficult to represent within a hierarchy.
To make a two-dimensional array in function parameter:
Code:int tab [10] [10] / * values pf * / function (tab) / * function call * / void function (int * array [10]) / * prototype (or int tab [] [10]) * /
Bookmarks