fork download
  1. #include <iostream>
  2. #include <vector>
  3. using namespace std;
  4.  
  5. void print_vector(std::vector<int>& v) {
  6. // Your implementation
  7. for(auto item : v) cout << item << " ";
  8. cout<<endl;
  9. }
  10. int main() {
  11. // your code goes here
  12. std::vector<int> v = {0,1,2,3};
  13. print_vector(v);
  14. return 0;
  15. }
Success #stdin #stdout 0s 5612KB
stdin
Standard input is empty
stdout
0 1 2 3