What is the main use of the function pointer?

Answer

Function pointers are the only way for "Interept programming". In UNIX all the Interepts are called using function pointers. This is mainly used in system programming.

Answer

its nothing but a pointer to function. which is similar to ptr to a variable, if we are saying ptr to a variable then it will hold address of the variable like that fn. ptr will have the address of the function..

one of the major application of the function pointer is call back function.. i.e callback.

Answer

Pointers to functions/methods/subroutines aka 'Delegates' are frequently used in .NET programming especially in EventHandling, MemberInvoking

Improve Answer Discuss the question "What is the main use of the function pointer?" Watch Question

First answer by Dghukkeri. Last edit by ComputerJy. Contributor trust: 294 [recommend contributor]. Question popularity: 73 [recommend question]


Research your answer:

Answers.com > Wiki Answers > Categories > Technology > Computers > Computer Programming > What is the main use of the function pointer?

Our contributors said this page should be displayed for the questions below. (Where do these come from)
If any of these are not a genuine rephrasing of the question, please help out and edit these alternates.
Function pointer in c?  Use of function pointer?  What is function pointer?  What is pointer function?  Usage of function pointer?  What is a pointer function?  What is a function pointer?  What is their main function?  What is pointer to function?  Use of argc in function main?  Is function and pointer the same?  What is main use of function pointer?  What are the main engneering function?  Why you need the pointer to a function?  What is main use of function pointer and give one example program in practical situvation?