海洋之心


私信TA

用户名:wanggongsheng

访问量:122489

签 名:

等  级
排  名 17
经  验 20491
参赛次数 3
文章发表 163
年  龄 26
在职情况 学生
学  校
专  业 计算机技术

  自我简介:

读研ing,平时不登录dotcpp

#include<stdio.h>
#define MAX(a,b,c) (a>b?((a>c?a:c)):(b>c?b:c))
double max(double a , double b ,double c);
int main(void)
{
	double a,b,c;
	scanf("%lf%lf%lf",&a,&b,&c);
	printf("%.3lf\n%.3lf",max(a,b,c),MAX(a,b,c));
	return 0;
}
double max(double a , double b ,double c)
{
	double t;
	if(a>b)
		t=a;
	else
		t=b;
	if(c>t)
		t=c;
	return t;
}


 

0.0分

0 人评分

  评论区