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.
haha - thanks! I took another look at what I did here, and found I could remove some unnecessary variables... See https://www.codewars.com/kata/reviews/6303b5b97dbd2b0001ae7189/groups/6334df038bc1b5000121da57
That's gold. xD
just NEVER use it in production code :D
if D < 0 then the 1st asprintf is evaluated (because of &&)
if D >= 0 then the 2nd asprintf is evaluated (because of ||)
ikr, lol, - tbh, it wouldn't make much sense to translate it to other higher-level languages - those tend to have a single routine for this kind of thing as part of their library.
hey its broken for me idk how to fix it, removed the line altogether and it worked on test but not attempt
It's the objective of the kata
very bad explenation
The kata first expects users to use recursion (see the title). However, as pointed out below, recursion is not actually tested. You just need to provide a code that passes the tests. If you do without recursion this is not cheating, it's a kata issue if alleged requirements are not tested, not yours. This kata does not make much sense as is.
Yes, do it recursively.
I find it to be perfectly cromulent for me.