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'm really upset that i've never thought of this
Oh.. God.. I see very clever solution and relize that i'm stupid..
I'm going to drown myself by stuffing myhead into toilet
Extra Package is good but not
I'm not sure why people are voting this as best practices. You're completely right as to why this answer is not optimal.
That's awesome, i tried to do it this way, but i had errors that "Arrays" was not found. By this example now i see how to do imports. Thank you :)
I should have used an Anonymous Array!
This is exactly what I did but it did not work for some reason and i mean literally exactly
This function needed to return an int array. One way to do this was to build a new array and add the min and max to it and then return. But here you are doing it in one step without giving the array a variable name. You create a new int[] and initialize it all in one line.
what does new do
the shortest code
but not very efficient. O(N Log N)
Agreed.
thanks for this! now i know you can declare variable in return.
That's basically the gist of it, yeah. It's clean, easily understandable and not verbose - but not the most efficient solution.
It's half-way clever for its brevity, but definitely not best practice due to inefficiency.
Loading more items...