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
Why not? lol
Nicely but slowly. In most cases we don't need to use this generic solution for every type.
Hi, I think, that Kata's example is not properly and can discourage. Below is example, that Kata offered to repeat:
logOnce = once(console.log)
logOnce("foo") // -> "foo"
logOnce("bar") // -> no effect
But it's not possible and no one of best solutions can do it (check it yourself). Why? Because "console.log" has their own "this" and in addition to "logOnce = once(console.log)" you must bind console's object like this:
logOnce = once(console.log).bind(console);
In this case function will be work fine. Please, fix example case or provide another one, because existing is mismatched
Guys, read the description, please: "calculateHypotenuse(3,4); // returns 5". Your function will return "5.000"