fork download
  1. #include <array>
  2. #include <iostream>
  3.  
  4. template <typename Iterator> void test(Iterator begin, Iterator end)
  5. {
  6. for(;begin != end; ++begin)
  7. std::cout << *begin << ' ';
  8. std::cout << '\n';
  9. }
  10.  
  11. int main()
  12. {
  13. std::array<std::array<int, 2>, 3> foo = {{{1,2}, {3,4}, {5,6}}};
  14. test(foo[0].begin(), foo[0].end());
  15. }
  16.  
Success #stdin #stdout 0s 2852KB
stdin
Standard input is empty
stdout
1 2