state = (1 * 214013 + 2531011) mod 2^31 = 2745024. We divide our state by 2^16 (without modifying the state itself)
What do you mean without modifying state itself? state= modifies state. Are we supposed to initally assign state a value and then create another variable that is equal to state mod 2^31?
Same!
Merged
Merged
Beautiful!
The Dart translation looks good.
Fixed in Crystal && JS
To fix in
Dart
Kotlin
Python
Ruby
TS
This comment has been deleted.
Интересная техника кода
This comment is hidden because it contains spoiler information about the solution
For people confused it wants you to:
I'm pretty sure at least. Dunno if this is a spoiler but feel free to mark it as if I'm giving away too much info.
state = (1 * 214013 + 2531011) mod 2^31 = 2745024. We divide our state by 2^16 (without modifying the state itself)
What do you mean without modifying state itself?
state=
modifies state. Are we supposed to initally assign state a value and then create another variable that is equal tostate mod 2^31
?Nice geometric kata)
Oh!!! good solution!!!
Updated test cases. Didn't do the PS, but recognize that it's a good suggestion. Marking resolved.
u forgot to close the suggestion
Loading more items...