Problem

Source: ISL 2003, used for Singapore TST 2004

Tags: number theory proposed, number theory



Let $x_0, x_1, x_2, \ldots$ be the sequence defined by $x_i= 2^i$ if $0 \leq i \leq 2003$ $x_i=\sum_{j=1}^{2004} x_{i-j}$ if $i \geq 2004$ Find the greatest $k$ for which the sequence contains $k$ consecutive terms divisible by 2004.