#include<iostream>
using namespace std;
int main()
{
int a, b, c, t;
cout << "Input three integers :\n ";
cin >> a >> b >> c;
if (a < b)
{
t = a;
a = b;
b = t;
}/*交换a、b的值*/
if (a < c)
{
t = a;
a = c;
c = t;
}/*交换a、c的值*/
if (b < c)
{t = b ;
b = c;
c = t;}/*交换b、c 的值*/
cout << "Big to small is:" << a << ' ' << b << ' ' << c << endl;
return 0;
}
输入数字后得到的结果不是大小排序,而是一串数字