编辑代码

#include <stdio.h>
int findMax(int a,int b,int c){
    int max = a;
    if (b>max){
        max=b;
    }
    if(c>max){
        max=c;
    }
    return max;
}


int main (int argc, char *argv[]) {
    //JSRUN引擎2.0,支持多达30种语言在线运行,全仿真在线交互输入输出。 
    int a,b,c,max;
	printf("请输入3个数字:");
    scanf("%d %d %d ",&a,&b,&c);
    if(a>b){
        max=a;
    }else{
        max=b;
    }
    if(max>c){
        printf("the max is %d",max);
    }else{  
        max=c;
        printf("the max is %d",max);
    }
	return 0;
}