#include<stdio.h> #include<string.h> #include<iostream> #include<algorithm> using namespace std; char a[21]; int main(int argc, char *argv[]) { while(~scanf("%s",a)){ sort(a,a+strlen(a)); printf("%s\n",a); } return 0; } /************************************************************** Problem: 1066 User: kirchhoff Language: C++ Result: Accepted Time:90 ms Memory:1520 kb
原文地址:http://blog.csdn.net/wdkirchhoff/article/details/42240629