回调函数
帐 号: 注册帐号
密 码:  找回密码
      记住用户名和密码
回调函数

#include

typedef void (* FP)(unsigned int a,unsigned int b);
//void DataDeal(FP PCB);
//void PointerReceive(unsigned int a,unsigned int b);
//void Pointer(unsigned int a,unsigned int b);
////////////////////////////////////////////////////////////////

void Pointer(unsigned int a,unsigned int b)
{

    a = (a>b)?a : b;
    printf("THE BIG ONE IS  = %d",a);
}
void PointerReceive(unsigned int a,unsigned int b)
{
    Pointer(a,b);
}
void DataDeal(FP PCB)
{
    unsigned int m,n;
    m  =  5;
    n  =  8;
    PCB(m,n);
}
void main(void)
{
    DataDeal(PointerReceive);
    getchar();
}

copyright:2016-2020|邮箱:imalib@vip.163.com

蜀ICP备16020986号