a is a two-dimensional array
Parameter passing
No. | Formal parameter | Arguments | Formal parameter type |
---|---|---|---|
1 | a[][size] | a | Array |
2 | (*a)[size] | a | Pointer to array |
3 | **a | b | Pointer pointer |
*b[size]
b[0]=a[0]; b[1]=a[1]; b[2]=a[2]
- The formal parameter is a [] [size], use a when calling. Array
- The formal parameter is (* a) [size], and the actual parameter is a. Pointer to array
- The parameter is ** a, which is used when calling. Pointer pointer
initialization
memset(a,0,sizeof(a));