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.
You are using operations which lose precision because numbers will be converted to floating point which is not sufficient for numbers with more than 53 bits.
But there was a similar bug also in the Ruby reference solution which I have fixed now.
Thank you, my solution passes now.
I merged a fix, can you please verify.
PHP: Reference solution seems to be wrong for big random integers:
Reference solutions of other languages show that
0
is correct.both users no longer active
duplicate suggestion
This comment is hidden because it contains spoiler information about the solution
Something broke in random Ruby tests. Some tests say that I have wrong answers, but when I check them through puts, it gives the correct values, those - my solution returns the correct answers, but the tests perceive them with different values
For example
def champernowe_digit(n)
...
p res #=> 6
res
end
#=> Random digit tested: 8563414405108046 - Expected: 6, instead got: 5
Marking this as resolved since I didn't receive a reply.
Thanks for letting me know. The test cases have been updated to work with Python 3.6 and Ruby 3.0
Python new test framework should be used (Refer this & this for more detail)
Ruby 3.0 should be enabled (Refer this & this for more detail)
Fixed.
Fixed.
Could you give an example?
Fixed.
Loading more items...