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 comment is hidden because it contains spoiler information about the solution
Ah, ok! Now everything is clear. As I said: I must have missed something. I would have bet
mu
was the value and not the index. Sorry for missunderstanding and thank you for the explanation. Anyway, maybe it's not a bad idea to define these two values again in this Kata rather than assuming everyone has copleted the other one before?Both sequences would be [0, 5]. mu is 0 since the cycle starts at the 0th element, and the distance between repetition is 5. mu is not the value of the element that starts the cycle, but the index. Do not ignore x0. I'd recommend you complete the "Greedy Algorithm" kata before attempting this one, as it explains cycle detection terms in greater detail: http://www.codewars.com/kata/5416f1834c24604c46000696
The integer division problem is irrelevant, since you're never going to be using the resulting number for anything other than equality and, e.g., 8 / 3 == 8 / 3 is always going to be true, even in JS.
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
This comment is hidden because it contains spoiler information about the solution