memory Limit Exceeded On problem K of ACM amman collegiate programming contest

Revision en1, by faceless_man, 2016-09-28 00:16:04

Hello All, I was solving the following question on codeforces .. But the thing is I am getting memory limit exceeded on test 2 on online judge .. here is my code. ..... can anyone suggest any better way out ? thanks... problem : Problem K My Code : Code

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en1 English faceless_man 2016-09-28 00:16:04 421 Initial revision (published)