mani100011's blog

By mani100011, history, 6 years ago, In English

Hi. Here's my solution for the latest div3 problem D : https://codeforces.me/contest/1385/submission/87172064

can somebody please help why it gets TLE? I checked my solutions with some accepted ones and the idea was the same.

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

»
6 years ago, hide # |
 
Vote: I like it +11 Vote: I do not like it

Most likely trying to memset f every test case is causing the TLE. If there are 20,000 test cases and you set 200,000 * 26 ints each test you'll run out of time.