题解 | #小乐乐计算函数#
小乐乐计算函数
https://www.nowcoder.com/practice/89238e99c36e450786ccf3a9e7481b7b
#include <stdio.h> int main() { int max(int a,int b,int c); int a,b,c; scanf("%d %d %d",&a,&b,&c); int x,y,z; x=max(a+b,b,c); y=max(a,b+c,c); z=max(a,b,b+c); double m; m=(double)x/(y+z); printf("%.2f",m); return 0; } int max(int a,int b,int c) { int z,h; int max2(int x,int y); z=max2(a,b); h=max2(z,c); return h; } int max2(int x,int y) { return x>y?x:y; }#牛客创作赏金赛#