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.
really clever, well done!
deque in this situation is miles faster than normal lists
This comment is hidden because it contains spoiler information about the solution
You're right. I agree. Thanks for your comment.
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
I can't spot how this handling the no-duplicates condition ?
Excellent code!
Thanks!
brilliant
Heh wow didn't think of it this way.
Codewars katas ALWAYS have you returning stuff instead of printing them out like other programming websites. Honestly, it's a much better way to do it.
And yes, that's probably where you've gone wrong. Hope it helps!
You're iterating over array2 and if array2 is an empty array [], then it's a NoneType, which is therefore, not iterable. Maybe add an exception handler or a check at the start of the code, that should help. :)
The first test case passes an empty list. That's probably the reason.
Loading more items...