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.
Shouldn't be any issue with modifying the given parameter as we are told that we "can assume that all inputs are valid integers".
From MDN:
"Parameters are essentially passed to functions by value — so if the code within the body of a function assigns a completely new value to a parameter that was passed to the function, the change is not reflected globally or in the code which called that function.
When you pass an object as a parameter, if the function changes the object's properties, that change is visible outside the function."
idk why, but it didn't work for me.
Agree that this shouldn't be considered best practice. Clean code tho.
nice! its like a simplified version of mine! :)
cool
Yeah! Simple and efficient method! Nice work champ!
27.7778 is enough.
haha smart
I like this...i dont know why.
This is stupid.Give computing and repetition to a computer,This is the meaning of its birth
Which is specified in the description.
The kata is what it is.
Hello starting with capital H gives error, the kata only accepts hello with small H.
Am a novice...so please forgive in advance...
I have seen most of the solutions, but they have hard coded to the index of "1", what if the array is not limited to just three numbers?
Most of the solutions will give 0 even if the array is [2,1,3,4,5]