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.
stauntonjr Unfortunately it was marked as a spoiler. It would probably have helped me, and I may still have been stuck, so I don't think it went too far. I had to skip in the end to see how it had been answered.
Thanks for the explanation. I skipped through to see the answers as I was perplexed, and I still didn't understand until I got here.
This is a terrible solution, brain-dead today!
This is an intense solution, were you experimenting?
I agree.
I'm glad you submitted this, I was trying to remember the syntax but got stuck as I was trying to use elif!
This comment is hidden because it contains spoiler information about the solution
I think it would be clearer if you described the i-th number in both cases.
I believe there is a typo. The description of the input array should be: "- the number of a friend who was given a gift by friend number i". At the moment it duplicates the description of the output array.
This comment is hidden because it contains spoiler information about the solution
I did this. With a whole bunch of uneccessary extra code ;-)
Same. Quickest solution, largest quantity of discussion messages!
Great, almost identical as mine (I prefered a <= here)
That's just what I was thinking!
divmod is useful here as it returns // and % in one call.
Loading more items...