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.
So many sugar pills. Hope they're hungry! :-D
They aren't chewing pills for 30 minutes. Making n things on an assembly line takes much less time than n times the time of making 1 thing.
This comment is hidden because it contains spoiler information about the solution
I think that it would be way too easy to figure out the pattern
Can you please provide a calculation example where he needs frieds? I´m not able to figure out the algorithm via the one example where he does not need friends. Thanks!
It is not clear enough, that m < n should lead to INVALID.
For example for me sumMult(8, 5) could also just return 0
Oh. And.
Please add random test cases.
I have taken the liberty of correcting some glaring spelling and logic errors in the description and the tests. Hope that's OK with you.
What is the added value of testing for invalid inputs? It adds one line of code to the solution and it has absolutely nothing to do with the calculations. I would suggest testing with valid inputs only, and specifying such in the description.
Also, operators apparently are placed between numbers only, and not in front of the first one. But we have to infer this from an example. It would be perfectly possible to have a
-
in front of the first number (and it might give more possible solutions). I would suggest explicitly specifying possible placement of operators in the description, not only that they don't go in front of the first number, but also what happens whento >= 10
- can we put+
or-
in the middle of10
or11
, or not ?Otherwise - fun kata! I was worried the number of possible answers would get out of hand in a hurry, but that remained quite managable. Thanks! :]