c++ - how to insert a vpii in vector<vector<pair<int,int> > > -


how insert vector pair in vector< vector < pair < int,int > > >

i beginner of stl please me

this how insert vpii in vector<vector<pair<int,int> > >:

vector<vector<pair< int,int> > > vvpii; pair<int, int> pii(1, 2); vector<pair<int, int> > vpii; vpii.push_back(pii); vvpii.push_back(vpii);  // or if compiler supports c++11, // can use brace-enclosed initializer lists vvpii.push_back({ // vector initializer     {1, 2}, // pair initializer     {2, 3}, // pair }); 

Comments

Popular posts from this blog

c# - How to get the current UAC mode -

postgresql - Lazarus + Postgres: incomplete startup packet -

javascript - Ajax jqXHR.status==0 fix error -