Ruby translation kumited :) please check and approve ~~
In the pre-defined test cases the $actual and $expected are reversed.
The definition is assertEquals(mixed $expected, mixed $actual).
This can be confusing in the error messages because the it shows the actual as the expected and vice versa.
Ohhh, it's my 1st kata where I gave up. After that 3 hours of trying I just hate it)
I wasn't looking for a job, it's just something I do because I like it. Also I haven't solved any 2 or 3 kyu katas, so I'm not really 2 kyu.
Hey! Short question. I saw you are 2 kyu. Did you get a job with python?
Great kata! Although I completed tons of kata that were somewhat similar, this one made me think for a while.
opinion, not an issue
A separate test for NULL may be good, but I don't think it's that necessary. free can be called with NULL.
Or even better approach if you need some other message for NULL:
cr_assert_str_eq(actual, expected, "Fail Message...");
cr_assert_str_eq crashes if passed NULL and then you need to check once again to free
So the best approach to test also for NULL and then to free is
if (!actual || strcmp(actual, expected))
Java Translation. Please review
Maybe the C or NASM versions are interesting but this is yet another boring string manipulation kata in Python.