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.
I don't get how this is possible, I'm using Heap's algorithm and I'm still getting time limit exceeded
Good kata, I took advice from a comment below and did the math on paper, then the implementation was trivial.
Are you not freeing a pointer that you allocated? I had this issue on another problem when I was starting out, and freeing the allocated variable fixed my issue.
Oh no, you actually had to implement something yourself and use your brain a little bit? Boohoo lol
You are right, this does not handle all possibilities correctly.