#include<stdio.h>
int main()
{
int num1;
int num2;
int num3;
int num4;
printf("输入三个数num1=%d,num2=%d,num=%d\n",num1,num2,num3);
scanf("%d%d%d",&num1,&num2,&num3);
if(num1>num2&&num2>num3){ //弱智型
num4=num1;
num1=num3;
num3=num4;
}
if(num1>num3&&num3>num2){
num4=num1;
num1=num2;
num3=num4;
num2=num3;
}
if(nu3>num1&&num1>num2){
num4=num1;
num1=num2;
num2=num4;
}
if(num2>num1&&num1>num3){
num4=num2;
num2=num1;
num1=num3;
num3=num4;
}
if(num2>num3&&num3>num1){
num4=num2;
num2=num3;
num3=num4;
}
printf("%d,%d,%d",num1,num2,num3);
return 0;
}
//正常如下
/*
int a,b,c,d;
printf("输入的三个数是:%d,%d,%d\n",a,b,c);
scanf("%d%d%d",&a,&b,&c);
if(a>b){
d=a;
a=b;
b=d;
}
if(a>c){
d=a;
a=c;
c=d;
}
if(b>c){
d=b;
b=c;
c=d;
}
printf("%d,%d,%d\n",a,b,c);
return 0;
*/
10-09
846
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)