a.c代码如下:
#include <stdio.h>
int main()
{
int a1=33;
int a2=21;
int maxNum=max(a1,a2);
int minNum=min(a1,a2);
Printf(“the max value is %d ,\n”,maxNum);
Printf(“the min value is %d, \n, minNum);
return 0;
}
max.c代码如下
int max(int a,int b)
{
if(a>b){
return a;
}else{
return b;
}
}
min.c代码如下
int min(int a,int b)
{
if(a<b){
return a;
}else{
return b;
}
}
onemoo