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.
Statement
Boxes can not be stacked on top of each other, these can only be placed on the floor.
from description was misleading for me. It only means that rectangles can not overlap.Binary search was overkill here. Perfomance tag means not to check every floor one by one.
Just wanted to improve my first solution after looking at other solutions. King is alive!
This comment is hidden because it contains spoiler information about the solution
How about example
w.j.##j###~~j.o..o#pjoj~~
? Jump over lady, but there are j or o between warior and lady.Approved
For person not familiar with floating-point arithmetic those parentheses are useless
Also from random tests:
3 * 17 - 4 / 12 + 2 - 14 / 8 / 8 = -Infinity
Nice challange! What was not so clear from description:
Each enemy in the chain gets half the damage done to the previous enemy.
[[4,1],[4,2]] after action A should be [[0,1],[2,2]]? First received damage 4. It can not receive damage more than 4. Looks like it should be [[0,1],[0,2]]How did you come up with this solution?
approved
From python radom tests. Looks like True.
has_partitions(10, 6, [(Point(4, 3),Point(6, 1)), (Point(7, 3),Point(11, 5)), (Point(7, 2),Point(6, 4)), (Point(5, 3),Point(6, 1)), (Point(7, 4),Point(7, 4)), (Point(5, 5),Point(5, 5)), (Point(5, 4),Point(10, 4))])
Only one transaction for a product_id per date is possible.
I can see several in random tests. So ambiguous order.What about customers who didn't make any rentals? As I see reference solution ignore them while taking "top 20%".
There is a room for performance improvement, but this kata is not about performance
Thank you, found my mistake
Loading more items...