Logic behind calling function by using “Pointer to a function”
问题 Suppose there is a pointer f declared to some function say int foo(int) as : int (*f)(int)=foo; While mentioning about calling foo() function by using this ponter which is passed as argument to some other function. I have come across a statement saying that both y=(*f)(x) and y=f(x) are same in C and calls function foo() ....(x and y are of int type). For arrays I know that if p is pointer to any array a. p[i]=*(p+i)=*(&a[0]+i)=*(a+i)=a[i] . So writing p[i] and *(p+i) are same thing. But I