Loading homepage
Input: useCycle("red", "green", "amber") Output: Initially "red"; successive cycle calls yield "green", "amber", then "red".
Input: useCycle(0, false, ""); call cycle() twice in one event Output: The current value becomes "" after React renders.
Input: useCycle() Output: [undefined, cycle], where cycle safely does nothing.
useCycle(...values) returns [currentValue, cycle]. The sequence initializes a positional cycle for one mounted React hook. cycle() advances state by one and wraps using the sequence length.