Hello I am trying to use push back in a 2D vector but I don't know how to. This is what I have:
1 2 3 4 5 6 7
vector <vector <BigInt> > matr;
for (BigInt i=0;i<rij;i++) {
for (BigInt j=0;j<kolom-1;j++) {
matr.push_back().push_back((i+1)^(pow-j));
}
}
I quickly invented something but that doesn't work obviously. it should be equivalent to this: (the only problem in the code below is that those indexes don't exist yet that's why I need push_back())
1 2 3 4 5
for (BigInt i=0;i<rij;i++) {
for (BigInt j=0;j<kolom-1;j++) {
matr[int(i)][int(j)]=(i+1)^(pow-j);
}
}