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.
Your decision is impressive. Understanding complex numbers is something I need to work on.
But did you actually check?
I updated the fork and as you can see, there isn't any meaningful difference in performances between the two, here. So the iterator performs the same without allocating the full list.
about "more readable", question of habits, I'd say
about early exit, well. Might be true, but not even sure (since python is interpreted and balbla, so builtins are faster than user made early exit codes, very often).
Anyway. Considering the size of the problem here, both will do for sure.
I don't really mind too much how people solve it. The original kata had all sorts of anti-cheat, but I enjoy creativity, anti-cheat has a habit of turning into an arms race between cheaters and authors ( ie, me ) and I have been bitten by false positives on that same original kata.
And the whole kata really is just a bit of a joke.
Don't get bummed out. Just enjoy what there is to enjoy. :]
just means you didn't get the logic behind ;) (because there is)
done
no all tests are fine