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
What are different storage class specifiers in c?
What is methods in c?
What is the difference between procedural and declarative language?
console I/O functions means a) the I/O operations done on disk b) the I/O operations done in all parts c) the input given through keyboard is displayed VDU screen d) none of the above
Why c is called a middle level language?
write a program in c language to print your bio-data on the screen by using functions.
I just typed in this program, and it is acting strangely. Can you see anything wrong with it?
What is wrong with this code?
Write a code of a general series where the next element is the sum of last k terms.
What is extern keyword in c?
What is difference between array and pointer in c?
Write a program to print fibonacci series without using recursion?
Explain what is a program flowchart and explain how does it help in writing a program?
When is a “switch” statement preferable over an “if” statement?
write a sorting prgm to sort 50 nos and sum them and also remove all the occurrences of 15 and print it?