Skip to content

Instantly share code, notes, and snippets.

@manojnaidu619
Last active July 21, 2019 14:25
Show Gist options
  • Save manojnaidu619/573c93928e8e5dfa79e8f3d1ce0db791 to your computer and use it in GitHub Desktop.
Save manojnaidu619/573c93928e8e5dfa79e8f3d1ce0db791 to your computer and use it in GitHub Desktop.
Multidimensional Vectors(2D) in CPP
#include <iostream>
#include <vector>
using namespace std;
int main(){
vector<vector<int>> name = {{1,2,3},{4,5,6}};
for(int i=0;i<name.size();i++){
for(int j=0;j<name[i].size();j++){
cout << name[i][j] << " ";
}
cout << endl;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment