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.
This kata does not shield against the quick-and-dirty but wrong solution which uses float/double. Please add this testcase:
It is the largest pair of consecutive perfect squares which fits into a signed 64 bit integer. Most float/double solutions here will fail this test.
I have added code to make sure that the second check matches the result against the original list
I had this problem before on another kata. After a few hours or a day my solution was suddenly visible...
Fixed.
Done.
This comment is hidden because it contains spoiler information about the solution
I have added some information about the constraints of
x
to the description. Do you think I should split the kata into two, one with shorter lists that can be solved with your solution and a second one with the longer test cases which requires a faster solution?