Блог пользователя mannu_the_coder

Автор mannu_the_coder, история, 10 лет назад, По-английски

Hello everyone! I got a WA on test case 59 in the second question of Manthan 2k16 633B — A Trivial Problem in the system testing phase of Codeforces . But when I checked the judgement protocol after the contest , I found that my answer for test case 59 was displayed incorrectly . Actually the correct answer for test case 59 was 0 and I was getting the same correct answer on ideone.com (link — Click Here To See Ideone Solution, but there was a different answer given by the judgement protocol for this test case because of which I got a WA which should have been correct. I have also provided a screenshot of the judgement protocol for this question(submission no. 16359094) (link — Submission Page. This problem is not only with me , many of my friends have faced the same problem . Therefore, the authors of this contest are requested to look into this issue.

  • Проголосовать: нравится
  • -22
  • Проголосовать: не нравится

»
10 лет назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

Same thing happened with me :p

»
10 лет назад, скрыть # |
 
Проголосовать: нравится +9 Проголосовать: не нравится

Write your own pow function.

»
10 лет назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

just see these links you may find something common Link1 Link2 Link3 Link4 Link5 Link6 and correct answer

»
10 лет назад, скрыть # |
 
Проголосовать: нравится +8 Проголосовать: не нравится

I am one of the authors of Manthan 2k16.

Sorry to say but your solution is incorrect. The 59th test case is m=99998. You have output 5 integers: n=[400000,400004], none of whose factorial has 99998 zeros.

»
10 лет назад, скрыть # |
 
Проголосовать: нравится 0 Проголосовать: не нравится

This is a case where I like Python; a translation of your solution works (16387562) because pow will return an integer if appropriate, and can also do modulo exponentiation.