Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
You are right~ I made a newer version. Thanks!
Someone actually saw this haha.
I was not trying to obfuscate it but I practiced DRY to the extreme, which I felt is very bad. Too much (improper) reuse of code made it unreadable..
The naming of the variable is also bad as I did not want the code to be long.
I was having fun writing that though, maybe the evil kind of fun.
This piece of code have some flaws as pointed by pacmanofgb and Djaler.
The latest version is http://www.codewars.com/kumite/559a3a13ca8d11efbd00006b?sel=55b04fd6c50a3237eb000011
You are correct.. I will modify it, thanks.. It was careless of me making these mistakes..
But people can always create their own linked list and copy everything to that with the same effect.
RAM is quite cheap now...
You are correct. I missed that. Thanks for pointing that out!
Should add 'and len(lst) == 4
The moment that I realized that I did not need to check for prime, I felt so stupid... The smallest factor is alway prime..
But there should be some speed-up for the dynamic programming part of generating primes...
Most people here just use the sort function, while the actual question is to find the n large one. I suggest to add test case with very long list and very small n and add a time limit.