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.
That's an awesome explanation, thanks!
Thanks, good to know!
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
Who does this keep double whitespaces?? You're just joining the reversed words by a single whitespace.
it doesn't matter if he use sizeof(char), as this would only consume compile time and it would become a constant.
Fixed
This mutates the original array, which was not forbidden by the description, but is probably why this rankes more on the "clever" than on the "best practice" side.
It is really pretty clever though, I have to admit.
Nice solution. Some nitpicks:
sizeof(char)
is by definition always1
, so it's kinda redundant to write that instead of just1
.malloc
,calloc
and friends and null terminate strings.realloc(final, temp - final)
in the end so you don't return a buffer that is longer than it needs to be.In that case it should be changed in the test cases. Either way, the function name in the solution stub should not have to be changed for the tests to pass. Currently you get an error (
error[E0425]: unresolved name 'DNA_strand'
).https://doc.rust-lang.org/1.0.0/style/style/naming/README.html
The Rust code misspells the function name (should be
DNA_strand
instead ofdna_strand
).