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.
Perhaps the kata could be made more interesting by requiring the class to be an
enum
, with membersGAS
,LIQUID
,SOLID
and a method (or an immutable final Map) that returns the correct transition name. There are relatively few kata that involve enums on Codewars.There are no reasons to run 1500000 tests unless you want to exhaust all possibilities of
hh:mm-hh:mm
, but that's very stupid. Unless it's for performance reasons, but why performance requirement in such a trivial kata? It's kinda of delving into micro-optimization category.Random tests are making double the amount of calls.
More worryingly, this happens because random tests are calling the user function twice and asserting the two results are equal, which means random tests are not working at all.
import java.util.Date
is missing in the initial code.Neat!
Nice solution!
You actually don't need the ternary conditional operator, because the default value of a boolean in Java is false.
Now it is working without the commented line. Thank you!
Could you please check again?
I mean the code which is correct but does not pass tests.
This comment is hidden because it contains spoiler information about the solution
Can you post the code which errors out?
In kotlin version: Incorrect answer for disks=64 expected:<0> but was:<18446744073709551615>
Please review the kotlin translation.
Parenthesis are unnecessary since
&&
has higher precedence than||
This comment is hidden because it contains spoiler information about the solution
Loading more items...