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.
Java:
camelCase
, notPascalCase
Refer here on how to enable backward compatability to not invalidate all solutions
Trivial map/filter/reduce is not a novel kata idea.
The random tests are making problems some times it expects 18 and the actual result is 9 (I think this is appropriate) and some times it expects 9 in case I change the "magic number" to 18. My solution passed on random generated value but please fix the tests. Thank you.
Why return the square root of the digit sum of the string as a string instead of just returning it as-is (i.e. as a double)? It adds an extra unnecessary step to the process and is a prime example of an anti-pattern (i.e. a practice discouraged in production environments) because the resulting value cannot be directly used in calculations (at least not before parsing the double from the string returned).