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.
I prefer it this way to be extra sure. I doubt it would slow it down much
This comment is hidden because it contains spoiler information about the solution
bad practice to reassign arguments
Length cannot be smaller than the number of keys. When setting a length, any elements beyond the new length are deleted.
I just try '010.013.037.01', the regex return false.
In the description, '010.013.037.01' expect return false too.
The easier solution is
String.prototype.reduce = Array.prototype.reduce
(well, watch out for enumerability).In any case, this is not an issue but more of a suggestion, so closing.
This comment is hidden because it contains spoiler information about the solution
Different application environments use different code.
if this is a very high performance requirements of the application environment, we should try to optimize the code to improve performance.
If not, try to streamline the code, to give the job to CPU, don't let yourself exhausted ;-)
So my conclusion is that, in codewars, as long as the code can pass all the tests will be enough.
If the author is concerned about the performance of the code, he will add some testcases about the performance.
Yea, it's cool, but it not so inefficient ;-)
I thought that each number in an IP address could not be preceeded with 0? In which case that IP should indeed fail.
I was just focused on the javascript solution looking exactly the same as the javasolution, really there was no need.. sorry
Hey thanks for reporting the issue. I had a look a the js translation of the kata and I believe I found the problem with the random tests. Could you please try again and let me know.
As per your first question maybe Matt, who provided the translation, could shade some light. I am in no position to discuss javascript best practices.
This comment is hidden because it contains spoiler information about the solution
Codewars doesn't provide you that functionality (yet), but you can do it by hand. I usually use a self-written banner, see http://www.codewars.com/kata/552679ea44a9e400b600124f for an example. Feel free to use the HTML/CSS:
Make sure to replace
x
,y
,!TOPIC!
and!LINK_TO_PREV!
.Loading more items...