1#include<iostream>
2#include<vector>
3using namespace std;
4/*
5Iterate over vector of vectors and for each of the
6nested vector print its contents
7*/
8template <typename T>
9void print_2d_vector(const vector< vector<T> > & matrix)
10{
11 for(auto row_obj : matrix)
12 {
13 for (auto elem: row_obj)
14 {
15 cout<<elem<<", ";
16 }
17 cout<<endl;
18 }
19 cout<<endl;
20}