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.
NASM translation
The input should not be named
sq
when it's stated in the problem that it might not be a perfect square.Scala translation
This comment is hidden because it contains spoiler information about the solution
what should I do if in c++ in the fourth test, the compiler does not execute the code correctly?
In the Rust version you have to return an Option, not answer or -1.
I spend so many time for resolve it, but test [TestCase(4503599627370497, ExpectedResult = -1)] not asserted. Then I thought that I didn't understand something and looked at the decisions of other participants. They were no different from mine and didn't pass this test either. C# lacks the precision to solve this test
In Rust code for this kata, the return type is specified as optional
u64
, which makes returning-1
impossible. From tests it is clear, thatNone
should be returned, yet it'd be helpful to also say this in the description.How is it possible to keep the function as long int if one of the test cases uses the value 15,241,383,936, which goes over the capacity of a long int? I had to change mine to long long int
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution