Discussion
typedef int (*PFI)(char *, char *)creates ___________
Answer: A
Correct answer: type PFI, for pointer to function (of two char * arguments) returning int
Read the declarator from the name outward, respecting the parentheses. PFI is inside (*PFI), so it is a pointer; the (char *, char *) that follows makes it a pointer to a function taking two char *; and the leading int gives the return type. Without the parentheses, int *PFI(char *, char *) would instead be a function returning int *.
No comment is present. Be the first to comment.
Loading…
Post your comment
Please log in or register to post a comment.
Examination Categories
- SSC Exams
- Banking Exams
- Teaching Exams
- Civil Services Exams
- Railways Exams
- Engineering Recruitment Exams
- Defence Exams
- State Government Exams
- Police Exams
- Insurance Exams
- Nursing Exams
- Other Government Exams
- NRA CET
- PG Entrance Exams
- Campus Placement
- MBA Entrance Exams
- CUET and UG Entrance
- Judiciary Exams
- Regulatory Body Exams
- Software Development