首页 > 试题广场 >

以下是两段C语言代码,函数arith()是直接用C语言写的,

[问答题]
以下是两段C语言代码,函数arith()是直接用C语言写的,而optarith()是对arith(0函数以某个确定的M和N编译生成的机器代码反编译生成的。根据optarith(),可以推断函数arith()中M和N的值各是多少?
*define M
*define N
int arith(int x,inty)
{
            int result=0;
            result=x*M+y/N;
            return result;
}

int optarith(intx,inty)
{
            int t=x;
            x<<=4;
            x-=t;
            if(y<0)y3;
            y>>2;
            returnx+y;
}

这道题你会答吗?花几分钟告诉大家答案吧!