提交时间:2021-06-19 17:19:58
运行 ID: 20668
#include<bits/stdc++.h> using namespace std; int main(){ int a,x,y,z,t,q; cin>>a; x=a%10; y=(a/10)%10; z=(a/100)%10; t=x; if(t<y)t=y; if(t<z)t=z; cout<<t; if(t==y){ if(x>z){ cout<<x<<z; }else cout<<z<<x; } if(t==z){ if(x>y) cout<<x<<y; else cout<<y<<x; } if(t==x){ if(y>z){ cout<<y<<z; }else cout<<z<<y; } return 0; }