fork download
  1. #include <iostream>
  2. #include <string>
  3. #include <algorithm>
  4.  
  5. int main()
  6. {
  7. std::string s("abcdefg");
  8. std::reverse(s.begin(), s.end());
  9. std::cout << s << "\n";
  10. return 0;
  11. }
  12.  
Success #stdin #stdout 0.01s 2812KB
stdin
Standard input is empty
stdout
gfedcba