fork(1) download
  1. #include <iostream>
  2. #include <vector>
  3. #include <algorithm>
  4. using namespace std;
  5.  
  6. int main() {
  7. // your code goes here
  8. vector<string> vs = {"abc", "def"};
  9. //vs.reserve(vs.size()*2);
  10. vs.insert(vs.end(), vs.begin(), vs.end());
  11. for (auto &s : vs){
  12. cout << ":" << s << endl;
  13. }
  14. return 0;
  15. }
Success #stdin #stdout 0s 3476KB
stdin
Standard input is empty
stdout
:abc
:def
:
: