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.
Like a few other kata I've seen, this is as much a math problem as a coding one. Unlike those, the math problem here is complicated and hard - the square pizza algorithm requires factoring n, which gets much harder as n increases. In combination with the large test numbers and the runtime limit, it becomes a "how many optimization tricks do you know" problem more than a math problem.
As-is, this is more difficult than I think it really needs to be. Depending on the difficulty level you're aiming for, I would recommend either:
Additonal suggestions: