Question 5
Triangle $ABC_0$ has a right angle at $C_0.$ Its side lengths are pairwise relatively prime positive integers, and its perimeter is $p.$ Let $C_1$ be the foot of the altitude to $\overline{AB},$ and for $n \ge 2,$ let $C_n$ be the foot of the altitude to $\overline{C_{n-2}B}$ in $\triangle C_{n-2}C_{n-1}B.$ The sum $\sum_{n=1}^{\infty} C_{n-1}C_n = 6p.$ Find $p.$