fork download
  1. #include <iostream>
  2. #include <string>
  3. #include <array>
  4.  
  5. int main()
  6. {
  7. std::string digits = "1234509876543216789010293";
  8. std::string strings[] = {{digits, 0, 5}, {digits, 5, 5}, {digits, 10, 5},
  9. {digits, 15, 5}, {digits, 20, 5}};
  10. for(const auto& s: strings)
  11. std::cout << s << std::endl;
  12. }
  13.  
Success #stdin #stdout 0s 3472KB
stdin
Standard input is empty
stdout
12345
09876
54321
67890
10293