Assistance for 689D

Revision en1, by miniluigi, 2016-07-08 04:38:49

I have tried to use the Sparse Table Algorithm in order to compute the RMQ in this problem. However, there must be some error in either the algorithm or the binary search as seem to be overcounting the number of ordered pairs. If anyone can find the error, I would greatly appreciate your assistance. Thanks!

Here is my submission: http://codeforces.me/contest/689/submission/18959583

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English miniluigi 2016-07-08 05:07:37 217
en1 English miniluigi 2016-07-08 04:38:49 407 Initial revision (published)