标签:style color io os ar for 数据 div sp
2 12345045789123 899000124
98755443322110 1122334455789 998421000 124899
#include<stdio.h> #include<string.h> #include<algorithm> using namespace std; int main() { int N,i; char a[110]; scanf("%d",&N); while(N--) { scanf("%s",a); int len=strlen(a); sort(a,a+len); for(i=len-1;i>=0;--i) printf("%c",a[i]); printf(" "); for(i=0;i<len-1;++i) if(a[i]!='0') break; for(;i<len;++i) printf("%c",a[i]); printf("\n"); } return 0; }
标签:style color io os ar for 数据 div sp
原文地址:http://blog.csdn.net/qq_18062811/article/details/39432209