0

Preventing of Execution Timed Out

I'm trying to solve solution "Word Rank". All algorithms work correctly, but if given word has more than 8 letters it terminated in 4-5 seconds with Execution Timed Out. How to prevent it?

22nd Dec 2020, 9:44 PM
Dmitry Lezin
Dmitry Lezin - avatar
3 Answers
+ 1
At last I have done a new solution based on your suggestion: calculate rank by the permutation formula, not by generating the full list of it. https://code.sololearn.com/cZZ62sGhD9ML/?ref=app
11th Feb 2021, 11:53 AM
Dmitry Lezin
Dmitry Lezin - avatar