devarshi09's blog

By devarshi09, history, 6 years ago, In English

I am not able to solve problem "once upon a time" from this(http://mirror.codeforces.com/gym/100963/attachments) set . I tried extended euclidean algorithm. Can anyone provide the solution (in form of code or editorial) for this problem Or help me debug my code (http://mirror.codeforces.com/gym/100963/attachments) .

Full text and comments »

  • Vote: I like it
  • 0
  • Vote: I do not like it

By devarshi09, history, 6 years ago, In English

I am getting WA in Spoj Problem ,Build the fence . Link to the problem : https://www.spoj.com/problems/BSHEEP/ Link to my code : https://ideone.com/NpcblK . Can anyone help me to find the error or give any counter test case. I used graham scan algorithm to make my code efficient.

Full text and comments »

  • Vote: I like it
  • 0
  • Vote: I do not like it

By devarshi09, history, 6 years ago, In English

How to calculate (a power b) mod p correctly if b is exceeding long long integer limit in c++.

Full text and comments »

  • Vote: I like it
  • +1
  • Vote: I do not like it