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.
A valid time with a trailing newline (e.g.
'12:30:00\n'
) should be added as a fixed test. Many solutions use regex patterns like/^([0-1]\d|2[0-3])(:[0-5]\d){2}$/
, but the'$'
token matches on different things depending on language, notably Python and Java, which will match the position before a terminal newline as well as the end of the string. Also, annoyingly, just replacing the'$'
with'\Z'
isn't always effective, as in Python,'\Z'
matches only the end of the string, while in Java it's just a synonym for'$'
.Java translation!
This comment is hidden because it contains spoiler information about the solution
JavaScript and Python use rounding + strict equality instead of approximate equality. (Ruby is OK)
should also be removed from the description
In Crystal the method name should be distance_between_points (snake case) not distanceBetweenPoints (camel case). Changing it will make it impossible to pass the final tests.
Haskell translation
Tests should use approximate equality instead of rounding + strict equality. Affected languages:
In JavaScript, I intentionally used a truncated form of
Pi
in order to point out that an incorrect solution could pass the kata.(not sure if this amounts to a legit
issue
but thought I would post it anyway, see what the community thinks)Adding fixed tests / altering the RTG would solve this.
Groovy Translation
This comment is hidden because it contains spoiler information about the solution
python:
assert_approx_equals
should be used.On java full suit of tests asserts this input "0X1e5" but on kata instructions is only defined for prefix "0x" and not "0X". I hope it helps. Maybe that information should be included on specifications.
Where i can leave my code to ask about his workable ?
Error messages in C++ present values with insufficient precision: see the question below.
Hi Taw,
Thanks for the Kata. By reading the challange too complex it tought me a lot.
Just as an idea:
Build in a check that is the trainee creates a "x class" in the solution; to point them in the right way.
Enjoy
Loading more items...