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.
Better output messages: was true or false expect?
the initial code should contain String, not string as a type declaration for Java.
Also maybe specify what the output should be if the input is not of the correct form.
State that 0 should be returned when the passed string is empty.
Currently: "But as a little hint, the solution to the this Kata is exactly the same as the example test cases."
Proposed: "But as a little hint, the test case that checks the solution is exactly the same as the example test case."
Why? I first understood that the solution (!= solution test case) is exactly the same as the example test cases. This may be because I am not a native english speaker, however, others may have the same issue.
Failure messages did not specify precisely why the test failed. I forgot the ! symbol at the end of the greetings string. It did not indicate that to me.
You can use getOrDefault since Java 8.
It should be stated that the ideal solution does this by hand and not by simply calling (i.e., delegating to) a single API method for this purpose.
Description should be more specific. What in case the input is {1,2}? Just take the first integer with odd occurrences?