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.
This comment is hidden because it contains spoiler information about the solution
naw, my professor would say keep it simple this looks just as bad as having the methods on multiple lines imo. While it is nice to know that these methods are possible what if there bug. Who is debugging this?
clever
This is the writing style of the Stream API.
Great solution !However in prod would expect something more readable, maybe only because I dont have much experiance
can you detail why ?
This comment is hidden because it contains spoiler information about the solution
love this because it's much more easy to comprehend than fluent methods that do lots of clever conversions (which I def ended up doing). I would much rather see this code in a production codebase!
Good for readability. Took 2300 ms for 10000000 runs
I believe this works, but it's very not-effecient solution
In my oppinion this is way to complicated
Clever two line solutions, but it is looping through the array two times.
not to mention many other solutions are O(n) but this is (n^2)...
I could be totally wrong here, I'm a bit of a newb, but is this really deserving of all the best practice votes? Creating 2 separate methods for what could easily be done with a couple for loops inside of findEvenIndex() just feels overly complicated.
This is a beautiful and clever solution, Great!
In addition, I think is better than the most popular solution (It's on the top)
because this solution takes O(n) and doesn't use a sort method (it would take O(n*lg(n)) like the most popular solution above).
Loading more items...