Large 2d array

This post was flagged by the community and is temporarily hidden.

1 Like

That is not possible to do for a[100000][100000].

2 Likes

whenever you find yourself in this kinda situation, you need to change your algorithm to not have this huge array size.

1 Like

You will get the approach soon in the editorial of the problem which you are trying to solve and that also after the contest is over. :blush::blush:

1 Like

i know but how can i solve qus if row and coloum size is like that.

You’ll have to optimize your algorithm in such a way that it doesn’t use a large 2D-array at all.

At max you can create a vector or an array of upto 10^8 that is you can initialise only these much cells of memory location in 1 seconds because it is not possible for an average machine to do more than 10^8 operations in a second. So for 2d array as per my so far knowledge and experience you can go upto [7000][7000] max…
Moreover these much memory is not required for any problem in CP you need to either change your approach or the whole algo to solve the problem

2 Likes

Message me on facebook.

Honestly, deleting a message means nothing if we can still read it clicking on the pencil.

3 Likes

it will deleted after 24 hr.

1 Like

sabko bta do tum aaise padh sakte

It is possible. You must not restrict your thinking only to simple Arrays. Google it,learn, try and implement and thats how you improve!

facebook message done check it.

1 Like