不知道有没有,不过求余数很好求。int yushu(int a,int b){ int c; c=a/b;//求商 c=a-c*b;//求余数 return c;}说明,a除以b的余数,在主函数里调用即可。
求余数可以直接int a,x,yx=10;y=3;a=x%y;