Example 5 A strip composed of $n$ squares, these $n$ squares are sequentially numbered as $1,2, \cdots, n$. Initially, one square is empty, while each of the other squares contains a piece. When a square contains a piece, and the two adjacent squares have one with a piece and the other without a piece, the second piece jumps over the first piece and is placed in the empty square, and at the same time, the first piece is removed from the strip.

When $n=2008$ and $n=2009$, find all possible initial positions of the empty square so that after the moves, only one piece remains on the strip.
To facilitate the description, the conditions and operations of the problem are redefined as follows, without changing their essence.

Let the situation where the $t$-th (1 ≤ t ≤ n) square is empty and the rest of the squares in a strip of length $n (n \geq 3)$ are occupied by chess pieces be denoted as $(n, t)$.

Similarly, a strip of length $n$ with the $i_{j}$-th (j=1,2,⋯,t) squares empty is denoted as $\left(n ; i_{1}, i_{2}, \cdots, i_{t}\right)$.
The operation defined in the problem can be understood as:
A chess piece $e$ can move one square to the right (left) if the adjacent square to its left (right) contains a chess piece (called the "colliding piece" of $e$), and the adjacent square to its right (left) is empty (called the "empty position"). When the chess piece $e$ moves into the empty position, the colliding piece of $e$ is captured (i.e., removed).

First, we prove a lemma.
Lemma: No chess piece can move two squares to the right (left).
Proof: Suppose there is a chess piece that can move two squares to the right, and let the leftmost such piece be $e$, which moves from the $i$-th square to the $(i+2)$-th square.

When $e$ moves from $i$ to $i+1$, the colliding piece in $i-1$ is captured by $e$, making $i-1$ and $i$ empty. To move $e$ from $i+1$ to $i+2$, there must be a colliding piece in $i$, which requires a chess piece to move from $i-2$ to $i$, contradicting the definition of $e$.

Next, assume that after a finite number of operations, only one chess piece remains in $(n, t)$.
Thus, after the first operation, $(n, t)$ becomes
$(n ; t-2, t-1)$
$=(t-2, t-2)+(n+2-t, 1) \quad (t \geq 3)$

or $(n ; t+1, t+2)$
$$
=(t+1, t+1)+(n-1-t, 1) \quad (t \geq 1).
$$

We can unify these two cases as
$(n ; s, s+1)=(s, s)+(n-s, 1)$.
Assume $1 \leq s \leq \frac{n}{2}$.
Let the chess pieces in $(s, s)$ be $e_{i} (i=1,2, \cdots, s-1)$, and the chess pieces in $(n-s, 1)$ be $f_{j} (j=n-s, n-s-2, \cdots, 1)$, where $e_{i}$ is in the $i$-th square and $f_{j}$ is in the $(n+1-j)$-th square.

By the lemma, the chess pieces in the two strips move independently and only interact once, i.e., one chess piece from each initial empty position enters the other strip.
Consider the strip $(s, s)$.
$e_{1}$ cannot move and can only be captured by $e_{2}$ as its colliding piece, so $e_{2}$ moves to the 3rd square; the prerequisite is that the 3rd square is empty, i.e., $e_{3}$ is captured by $e_{4}$ as its colliding piece, so $e_{4}$ moves to the 5th square; ... by induction, $e_{2i-1}$ is captured by $e_{2i}$, and $e_{2i}$ first moves to the $(2i+1)$-th square. Therefore, $s$ must be odd.

Similarly, $f_{2j-1}$ is captured by $f_{2j}$, and $f_{2j}$ first moves to the $(n-2j)$-th square, and $n-s$ must be odd. Therefore, $n$ must be even.
Let $A=\left\{e_{2i} \mid 2i \leq s-1\right\}$, then the prerequisite for the chess pieces in $A$ to capture each other is that $e_{s-1}$ moves back to its original position. Similarly, the prerequisite for the chess pieces in $B$ to capture each other is that $f_{n-s-1}$ moves back to its original position. However, $e_{s-1}$ and $f_{n-s-1}$ meet at the $s$ and $(s+1)$-th squares, allowing only one chess piece to move back to its original position, and the other will be captured, leading to a contradiction.
Therefore, $|A|=1$.
Then $s=3 \Rightarrow t=2$ or 5.
Finally, verify that $(2m, 2)$ and $(2m, 5)$ satisfy the conditions.
$(2m, 2) \rightarrow (2m ; 3,4) \rightarrow (2m ; 1,2,4)$
$\rightarrow (2m ; 1,2,5,6) = (2m-2 ; 3,4)$
$\rightarrow \cdots \rightarrow (4 ; 3,4) \rightarrow (4 ; 1,2,4)$;
$(2m, 5) \rightarrow (2m ; 3,4) \rightarrow (4 ; 1,2,4)$.
In summary, only
$(2m, 2)$, $(2m, 5)$, $(2m, 2m-4)$, and $(2m, 2m-1)$ can result in only one chess piece remaining after a finite number of steps. Returning to the original problem:
When $n=2008$, the initial empty positions are $2$, $5$, $2004$, and $2007$.
When $n=2009$, there are no positions that satisfy the condition.