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
Nevermind, I seem to be overthinking this, it all works fine :)
This comment is hidden because it contains spoiler information about the solution
Why does this work, but not when you expand it?
The Math.ceil() function in JavaScript is used to round the number passed as parameter to its nearest integer in Upward direction of rounding i.e towards the greater value.
You should add a test for a rather large list, so that solutions that are not tail-recursive produce stack overflows.
can you please explain it
Most of the solution to this kata is not recursive !!!
can you please add some sort of validation
Thanks
I found this kata more difficult in javascript as compire to Python !!! Great kata
Can you please explain your solution?
I know you didn't mention my English, but other than that I cannot thing of much more: basically you just need to do some currying to a filter function:
filter1
parses numbers as explained in the description, given the initial array and integer as initializing parameters.^_^
After 2 hours of struggling !!! I did it , Great kata :)
Hey, I didn't say anything about your english, You speak good english,much better than me!!!
Problem is with me,
i am failing to understand this kata even though i tried with examples.
that's why i need your help,can you please explain me with one example -
filter1 = shortenNumber(['','k','m'],1000); // return a function which takes one argument,
filter1('234324') == '234k'; // How '234324' => '234k'
filter1('98234324') == '98m'; // How '98234324' => '98m'
filter1([1,2,3]) == '1,2,3'; // this one i got it, if function didn't get a string argument, function 'll return argument.toString()
thanks again !!!!
Let's try this: does working through the example test cases gives you a better insight than the one you might get trying to decypher my poor English?
Loading more items...