搜索
查看: 549|回复: 4
打印 上一主题 下一主题

完全按照书上写的,但是现实编译失败

[复制链接]
跳转到指定楼层
楼主
 楼主| 发表于 2018-10-17 20:58:31 | 显示全部楼层 回帖奖励 |倒序浏览 |阅读模式
5啊哈币
#include <stdio.h>
#include <stdlib.h>
int main()
{
     int max4(int a ,int b,int c,int d);
     int a,b,c,d,max;
     printf("pleas enter 4 number;");
     scanf("%d%d%d%d",&a,&b,&c,&d);
         max=max4(a,b,c,d);
     printf("the max = %d\n",max);
     system("pause");
         return 0;
}
  int max4(int a ,int b ,int c ,int d )
{   
   int max2(int a,int b);
   int m;
   m=max2(a,b);
   m=max2(m,c);
   m=int2(m,d);
   return(m);
}   
    int max2(int a ,int b)
{  
     if(a>=b)
       return a;
     else
       return b;

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

广播台
特别关注
快速回复 返回顶部 返回列表