tminh_hk20's blog

By tminh_hk20, 12 months ago, In English
  • The first time I encountered this problem was 567E - President and Roads. I had an overflow error and WA in test 104: 233996380. Then, I just MOD the computational array by a prime number to avoid overflow, but it helps me Accept: 233999386. I was so surprised because I use MOD to fix overflow errors.
  • The second time I encountered this problem was 348B - Apple Tree. I had an overflow error and runtime error on test 10: 236300131, and I did the same thing as Mod for a prime number. It's also helped me Accept: 236300470.
  • I don't think Mod to avoid overflow is a technique to accept any problem like them, but I can't explain why it helps me Accept the 2 problems above. I think luck makes me Accept them.
  • Vote: I like it
  • 0
  • Vote: I do not like it