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 think this is better practice than parsing values directly into 'return'
You did it like a Boss!
you can return the string dirctly
return "text";
Why Object.assign(this, {firstName}) is used here instead of this.firstName=firstName? I haven't seen this method mentioned in a JavaScript book.
upd: copies into an object... Genius!
perfect examples of a simple problem solved with something that is really not worth trying to understand
Wouldn't this convert the full array to list first and then provide index of match?
why traverse through full array, when we can "return" upon finding the "needle" with a simple for loop, thoughts?
nice work
Aprendi algo nuevo, gracias a ti. Object.assign() ... Saludos de Salta,Argentina.
Someone can give me feedback about my solution?
Doesn't work if input parameter haystack=null. Need to add checking for null input.
Never thought about this, amazing!
Best practice is what people voted best practice. You must get used to it, and if you don't agree, you are free to vote for whatever you think is good practice.
why is this best practice? if statements are much more readable
Genius my friend , genius
I really like this . Its so clean !
Loading more items...