#include“stdio.h”
ints_max(inta,intb,intc)
{
intmax;
if(a>=b)
max=a;
else
max=b;
if(max max=c; returnmax; } ints_min(inta,intb,intc) { intmin; if(a>=b) min=b; else min=a; if(min>c) min=c; returnmin; } floats_pin(inta,intb,intc) { floatpin; pin=(a+b+c)/3.0; returnpin; } mian() { inta,b,c; printf("请输入三个整数:"); scanf("%d,%d,%d",&a,&b,&c); printf("这三个整数中的最大值是:%d",s_max(a,b,c)); printf("这三个整数中的最小值是:%d",s_min(a,b,c)); printf("这三个整数的平均值是:%f",s_pin(a,b,c)); getch(); } 扩展资料 11H1333:三个数的最大值 #include usingnamespacestd; intmain(){ inta,b,c; cin>>a>>b>>c; cout< return0; }