You are viewing a single comment's thread. Return to all comments →
Here is my code
using namespace std;
int main() {
int n ; cin >> n; int q ; cin >> q; vector<vector<int>> arr(n); for (int i = 0; i < n; i++) { int k ; cin >> k; arr[i].resize(k); for (int j = 0; j < k; j++) { cin >> arr[i][j]; } } for (int j = 0 ; j < q ; j++) { int x, y ; cin >> x >> y; cout << arr[x][y] << endl; } return 0;
}
Seems like cookies are disabled on this browser, please enable them to open this website
Variable Sized Arrays
You are viewing a single comment's thread. Return to all comments →
Here is my code
include
include
include
include
include
using namespace std;
int main() {
}