fork(3) download
  1. #include <iostream>
  2. #include <string>
  3. #include <algorithm>
  4. using namespace std;
  5.  
  6. int main() {
  7. string str;
  8. cin >> str;
  9. for(char c = 'a'; c <= 'z'; c++) {
  10. for(size_t i = 0; i < str.length(); i++) {
  11. if(str[i] == c) {
  12. cout << str[i];
  13. break;
  14. }
  15. }
  16. }
  17. cout << endl;
  18. return 0;
  19. }
Success #stdin #stdout 0s 15240KB
stdin
blyadsukaaaaa
stdout
abdklsuy