输入3个整数,按大小顺序输出

来源:百度知道 编辑:UC知道 时间:2024/05/22 07:14:35
#include "stdio.h"
void ff(int c,int d)
{
int t;
t=c;c=d;d=t;}
main()
{
int a,b,c,t;
printf("please input three numbers\n");
scanf("%d%d%d",&a,&b,&c);
if(a<b)
ff(a,b);
if(a<c)
ff(a,c);
if(c>b)
ff(b,c);
printf("the sorted numbers are:%d,%d,%d\n" ,a,b,c); }
哪里错了?????

幼儿缺锌和缺钙的特征有哪些区别?如何治疗? 幼儿缺锌和缺钙的特征有哪些区别?如何治疗? 幼儿缺锌和缺钙的特征有哪些区别?如何治疗? 幼儿缺锌和缺钙的特征有哪些区别?如何治疗? 幼儿缺锌和缺钙的特征有哪些区别?如何治疗? 幼儿缺锌和缺钙的特征有哪些区别?如何治疗? 幼儿缺锌和缺钙的特征有哪些区别?如何治疗? 幼儿缺锌和缺钙的特征有哪些区别?如何治疗? 幼儿缺锌和缺钙的特征有哪些区别?如何治疗?

#include<stdio.h>
main()
{
int a,b,c,max;
printf("请输入三个整数:");
scanf("%d,%d,%d",&a,&b,&c);
max=((a>b)?a:b)>c?((a>b)?a:b):c;

if (max==a)
printf("%d\t%d\t%d\n",a,b>c?b:c,b<c?b:c);
if(max==b)
printf("%d\t%d\t%d\n",b,a>c?a:c,a<c?a:c);
if(max==c)
printf("%d\t%d\t%d\n",c,a>b?a:b,a<b?a:b);

} 你那是写的什么狗屁

#include "stdio.h"
ff(int *v,int *u)
{
int t;
t=*v;*v=*u;*u=t;
return;
}
main()
{
int a,b,c;
printf("please input three numbers\n");
scanf("%d,%d,%d",&a,&b,&c);
if(a<b)