[Help] Doubt Regarding Using Mo's Algorithm for 86D

Revision en2, by Vicennial, 2016-10-24 21:19:15

86D - Powerful array

I tried implementing Mo's Algorithm to solve this problem but I ran into a couple of TLE's when taking block size as sqrt(Max N) which is 448.
The submission can be viewed here-21756475 The result was TLE when using block size=448.
In the next submission-21756591 , I put block size=1000 and the result was AC.

So my question is how do I figure out what value to use as my block size?

Tags 86d, mo algorithm, time limit exceeded

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English Vicennial 2016-10-24 21:19:15 0 (published)
en1 English Vicennial 2016-10-24 21:18:22 492 Initial revision (saved to drafts)