How do I declare an array of N pointers to functions
returning pointers to functions returning pointers to
characters?
Answer Posted / kar4you
Answer: We have a three ways for declaring techniques:
1. char *(*(*a[P])())();
2. Build the declaration up in stages, using
typedefs:
typedef char *pc; /* pointer to char */
typedef pc fpc(); /* return function pointer to char */
typedef fpc *pfpc; /* pointer to above */
typedef pfpc fpfpc(); /* returning function */
typedef fpfpc *pfpfpc; /* pointer to*/
pfpfpc a[P]; /* array of*/
3. Use the cdecl program, which turns English into C and
vice versa:
cdecl> declare a as array of pointer to function returning
pointer to function returning pointer to char
char *(*(*x[])())()
| Is This Answer Correct ? | 6 Yes | 1 No |
Post New Answer View All Answers
Why shouldn’t I start variable names with underscores?
What is the difference between %d and %i?
What is function prototype in c with example?
When do we get logical errors?
Differentiate between the = symbol and == symbol?
How do we make a global variable accessible across files? Explain the extern keyword?
What are the three constants used in c?
pierrot's divisor program using c or c++ code
What is file in c preprocessor?
Why dont c comments nest?
How do you search data in a data file using random access method?
What is the use of header files?
what are the facialities provided by you after the selection of the student.
Compare array data type to pointer data type
What is meant by keywords in c?