Codeforces and Polygon may be unavailable from December 6, 19:00 (UTC) to December 6, 21:00 (UTC) due to technical maintenance. ×

0x0002's blog

By 0x0002, history, 14 months ago, In English

I was trying to solve 25E, I used hash and passed it, this is my submission. There is also a similar problem in SPOJ, link. The difference is only that the problem in SPOJ has $$$T$$$ test cases, where codeforces has only one.

I clear for every test, but got wrong answer in SPOJ. Is my algorithm wrong or there is some corner cases i didn't realize? Thanks.

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