Please read the new rule regarding the restriction on the use of AI tools. ×

SJ_SJ's blog

By SJ_SJ, history, 3 weeks ago, In English

Hello,

I was solving this problem , 414B - Mashmokh and ACM .

I coded up a memoized recursive solution 280651342 for the problem but I ran into recursion limit issues in python.

I searched for same issue in codeforces and came across this blog (https://codeforces.me/blog/entry/80158) , according to which I added bootstrap function into my code but I am still getting TLE

Note that I have already accepted the bottom up dp solution and the same memoized solution in cpp.

All I am asking for is if there is a way to get my solution (memoized recursion) to pass in python.

  • Vote: I like it
  • 0
  • Vote: I do not like it

»
3 weeks ago, # |
  Vote: I like it 0 Vote: I do not like it

Auto comment: topic has been updated by SJ_SJ (previous revision, new revision, compare).