You are viewing a single comment's thread. Return to all comments →
instead of using
int** seq=new int* [n];
you can have
int* a[N];
which reduces complexity a bit. And don't forget to deallocate memory before exiting via
for (int i = 0; i < N; ++i) delete[] a[i];
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 →
instead of using
you can have
which reduces complexity a bit. And don't forget to deallocate memory before exiting via