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.
Does not work properly when a negative number is given
This is cool, but it's not easy to read. Code should be as simple and easy for readability and maintainability.
true this is a good case of bad pratices the code should be/try to be easy to read to any person new to the code
Difficult to read
Mine is similar :)
So many votes for this being best practice. This is not best practice. Readability > Complexity.
Do only I have to my_eyes.split() to read that code?
If you want
ridiculous
, check mine out, lolAnd we all seek ridiculous one-liners in solutions section - that's a lot of fun.
In my opinon, his solution is easier to read thatn yours, and you have used too many unneccesary lambda functions further increasing the complexity. The other solution did the same thing without the use of multiple or no lambda functions :)
yes but ruby probably created like 1 million objects under the hood which is why this is the slowest lol
Well I'll be damned...
seriously!? :)
also the short versions will usually pop up as the first - meaning those that dont plan on looking through lots of different solutions will just drop their vote on the first clever-looking solution they see, and move on.
I'm pretty sure this one-liner will get you failed in a google interview. More than one "for" clauses in a list comprehension is not permitted per Google style guide 2.7.4. When things get complicated they'd rather see for loops, even though list comprehension has an internal overhead optimization (about 2x faster).
Loading more items...