Akuver's blog

By Akuver, history, 3 years ago, In English

I was wondering if there is a way to solve this problem. Suppose we have x^2 = k mod m, and we know the values of k and m. Now, is it possible to find z such that x = z mod m from only k & m ?

P.S.: Sorry for not using latex. I don't know how to do it on codeforces.

Full text and comments »

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

By Akuver, history, 4 years ago, In English

Here is my solution for the problem 6B(https://codeforces.com/contest/6/problem/B): https://codeforces.com/contest/6/submission/71870236 On my machine when I enter the sample test case, I get the correct answer. However, codeforces shows answer as 3 for my code instead of 2. Help me with the issue.

Full text and comments »

  • Vote: I like it
  • -9
  • Vote: I do not like it

By Akuver, history, 4 years ago, In English

I was going through the solutions of various contestants for the problem 1287B. However, I was not able to understand the one that I hereby attach

https://codeforces.com/contest/1287/submission/68285034

There is a statement x[i]^= 66^t[i]; Now, I worked out what it does but , what I cannot get is how 66 was obtained? Is there a mathematical approach being followed or is it just by inspection?

Full text and comments »

  • Vote: I like it
  • -5
  • Vote: I do not like it

By Akuver, history, 4 years ago, In English

I can't understand what is wrong with this piece of code of mine as a solution of the problem 158A: https://codeforces.com/contest/158/submission/67632208 Then I submitted this solution and it worked: https://codeforces.com/contest/158/submission/67947459 Please help me understand why the code that I submitted earlier fails.

Full text and comments »

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