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.
There might be an equation somewhere that you can use to calculate the distance between two points
Not quite sure where to start with this one.
Not a kata issue, closing - and please double-check your issues before you raise them :)
Thank you so much for your explanation and the function explaining it. I tested it and it worked with my assumptions in the way your functions explained. I shall look more into bitwise operations as well.
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
English can be weird. "Every other" and "all others" mean entirely different things.
No, "every other" number means in English that you remove 2, keep 3, remove 4, keep 5, &c.
So alternate keeping and removing, in alternating directions.
Hi. Please use spoiler flag next time. And please read this:
OP solved it closing ~~
Understanding the kata is the kata ;)
I figured it out.
Looking at the other solution makes me want to kill myself. :-D
I always hated the stock markets, and now I know why.
That is part of the kata to figure that out. Make sure you maximise profit.
Then the same question remains: how to tell when you're buying or selling?
it's not fixed on the number of the day
If you buy at the first 5 days, you'll pay 1+2+3+4+5 = 15 and have 5 stocks. The 6th day you sell 5 stocks for 6 per stock, rendering 30 revenue. 30 - 15 = 15.
Any other combination of choices you make will not give you 15 or more profit.
Loading more items...