answersLogoWhite

0


Best Answer

A pointer to a function is the memory address that stores the address of a function, while the pointer itself is a function pointer.

A pointer to a function might be defined as "int (*pf)(int, int);", while to actually point to the function, you would use a function pointer, such as "pf = &func;".

User Avatar

Wiki User

11y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What is the difference between a function pointer and a pointer to a function?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

Give the difference between function and pointer in c?

There is no similarity between the two.


What is the difference bw function pointer and function of pointer?

function pointer is a variable that hold the address of any function which declared in the program but function pointer is the array of the function that accept the run time size of the function.


Difference between pointer to constant and constant pointer?

1. pointer to a constant means you can not change what the pointer points to 2. constant pointer means you can not change the pointer.


How can you declare a pointer function?

*function();this declares a pointer function!


Difference between genric pointer and normal pointer?

Generic pointer of type 'void *' is compatible with any (data-)pointer, but you cannot use the following operators on it: + - ++ -- += -= * -> []


What is the difference between value type parameters and reference type parameters?

When a variable is passed by value, the function receives a copy of the variable. When a variable is passed by reference, the function receives a reference, or pointer, to the original data.


What is the difference between structure and pointer?

A structure is a collection of primitives or other structures. A pointer is a memory address. Comparison of the two is like comparing bowling balls to cinder blocks. You can say that a structure defines the layout of the data, while a pointer points to data that is a particular structure.


Example of fundamental difference between a polynomial function and an exponential function?

fundamental difference between a polynomial function and an exponential function?


What is the difference between a power point and a white pointer shark?

dfs sd


C program pointers to pointers examples?

Pointer to Pointer is a double pointer, denoted by (**). Pointer stores the address of the variable and pointer to pointer stores the address of a pointer variable and syntax can be given as int **ptr2ptr;


Difference between void pointer and null pointer?

A Null pointer has the value 0. void pointer is a generic pointer introduced by ANSI. Before ANSI, char pointers are used as generic pointer. Generic pointer can hold the address of any data type. Pointers point to a memory address, and data can be stored at that address.


Difference between normal function inline function?

gffg