Interview points:CClassical language interview questions
CAnalysis of language interview questions 5
I. Typical questions about C language pointers
A) An integer)
B) a pointer to an integer (a pointer to an integer)
C) a pointer to a pointer pointing to an integer (a pointer to a pointer)
To an integer)
D) an array of 10 integers (an array of 10 integers)
E) an array with 10 pointers pointing to an integer (an array of 10 pointers
Integers)
F) A pointer to an array with 10 integers (a pointer to an array of 10 integers)
G) a pointer to a function. The function has an integer parameter and returns an integer (a pointer to a fu ).
Nction that takes an integer as an argument and returns an integer)
H) An array with 10 pointers pointing to a function that has an integer parameter and returns an integer
Number (an array of ten pointers to functions that take an integer argument and R
Eturn an integer)
The answer is:
A) int A; // an integer
B) int * A; // a pointer to an integer
C) int ** A; // a pointer to an integer
D) int A [10]; // an array of 10 Integers
E) int * A [10]; // an array of 10 pointers to Integers
F) int (* A) [10]; // a pointer to an array of 10 Integers
G) int (* A) (INT); // a pointer to a function a that takes an integer argument
And returns an integer
H) int (* A [10]) (INT); // an array of 10 pointers to functions that take an int
Eger argument and return an integer