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.
Unnecessary, but pythonic -
Explicit is better than implicit
. Many linters would flag this function if you leftreturn None
out (and rightly so)Fixed
Fixed
Fixed 2. The others are not really issues and the info about input is abundantly clear.
Removed the mention of their site, clarified the None/nil/null issue from the description
I refactored the description and improved the tests so this should not be a problem. Marking resolved.
I improved the tests and description. I think they are now quite reasonable for a simple kata like this.
Well, the original author came up with the name for a kata series, obviously there is nothing to force someone to code fast on CodeWars. Getting the bits and pieces of the tests is also a part of the exercise. I refactored the description a little and improved tests and am marking this solved.
Fixed the issue
Please, please don't upvote this as Best Practices nor Clever. It looks nice, is a one-liner but its inefficient both through use of count and using a list instead of generator.
I'm sorry to burst everyone's bubble but this solution is certainly not a best practice. It creates a completely needless list when a loop based solution could just return after one iteration (not to mention the fact that str is called 10 times instead of 1 for each of num1 and num2).
Only recently did I realize that you have to choose a "main" tag from a short list. Thus "fundamentals" is probably the best, given limited choices, so please disregard the tag part of the comment and thanks for updating description/test cases.
You're absolutely right I just wanted to write something easy and readable.
The tests are fine. You are simply trying to do something 'illegal' with a list. Maybe using set()?
For everyone else wondering (or in case you still do) look here https://docs.python.org/3/library/urllib.parse.html#urllib.parse.quote
Loading more items...