pub fn collatz_sequence(n: u64) -> Vec<u64>
Compute the Collatz sequence starting from n until it reaches 1.