函数指针
#include<stdio.h> void(*fun(void (*)(int),int))(int); //void(*)(int) fun(void(*)(int), int); void fun1(int a); int main(int argc, const char *argv[]) { int num = 123; fun(fun1,num); return 0; } void(*fun(void(*p)(int),int n))(int) { p(n); } void fun1(int a) { printf("a = %d\n",a); }
标签:fun1,int,void,num,fun,函数指针 From: https://www.cnblogs.com/ruilovekeke/p/17324322.html