Solution:
This solution uses the following lemma.
Lemma. If a palindromic, finite sequence (an)n=1n=l of length l is periodic with periods x and y with x<y and x+y≤l+1, it is periodic with period y−x.
Proof. For r≤x−1, we have r+y≤l and x<r+y, so by periodicity with y and x, we have ar=ar+y=ar+y−x.
For x<r≤l−(y−x), we have 1≤r−x≤l−y, so by the periodicities we have ar=ar−x=ar−x+y.
It remains to be proven that ax=ay. In case x+y≤l, the first of the two above arguments works for r=x and shows ax=ay, proving the lemma.
However, in case x+yll, by the condition of the lemma we have x+y=l+1. Then by the palindromic condition, ax=al+1−x=ay. This finishes the proof of the lemma.
Comment. Via Euler's algorithm, we may use the lemma repeatedly to give that the sequence is periodic with gcd(x,y).
As in the previous solution, we use that for all n≥2,a[bn] is periodic with period bn−bn−1. Then as a[bn] is a subsequence for a[bn+1], we have that a[bn] is also periodic with period bn+1−bn.
Now let's apply the lemma's remark for a[bn], which we know is palindromic. The two periods are bn−bn−1 and bn+1−bn. The condition x+y≤l+1 translates to bn+1−bn−1≤bn (noting that l=bn−1 ). However, this is satisfied by the problem statement, so we get that a[bn] is periodic with period gcd(bn−bn−1,bn+1−bn).
Recalling that a[bn+1] is periodic with period bn+1−bn, which is a multiple of the period we got for a[bn]. Since bn+1−bn≤bn−1≤bn−1, an entire larger period is contained in a[bn]. Then each larger period in a[bn+1] consists of smaller periods of length gcd(bn−bn−1,bn+1−bn) from a[bn], so a[bn+1] is also periodic with period gcd(bn−bn−1,bn+1−bn).
Then substituting n+1 by n, a[bn] is periodic with period gcd(bn−1−bn−2,bn−bn−1). So by the remark, it is periodic with period gcd(bn−1−bn−2,bn−bn−1,bn+1−bn). By repeatedly using the multiple-period argument, substituting n+1 by n and using the remark, we get that a[bn] is periodic with gcd(b2−b1,b3−b2,…,bn+1−bn).
Since (gcd(b2−b1,b3−b2,…,bn+1−bn))n is a strictly decreasing positive integer sequence, it has a minimum which it achieves at some n=k. Then for p=gcd(b2−b1,b3−b2,…,bk+1−bk), we have that a[bn] is periodic with period p for all n≥k. This finishes the proof.
Comment. The lemma is true even if the palindromic condition is dropped. This stronger formulation requires a more in-depth, harder proof for the case x+y=l+1, presented below.
Proof. We repeatedly perform the following moves, starting from index x. If the current index is at most l−x, we increase it by x. If we cannot perform this move, and the index is at least y+1, we decrease it by y. If we cannot perform either move, we stop.
If at some point we cannot perform more steps, the index r we have satisfies l−x<r<y+1, so r=y. Since at each step the elements of (an)n=1n=l at the old and new index are equal due to periodicity, the elements at the first and last indices in our steps are equal, so ax=ay.
If we can perform the above steps infinitely many times, there will be an index at which we arrive at least twice. Let r1 be the first such index. Then let the subsequent indices we get by the above steps from r1 be (rn)n≥0. Since r1=rk+1 for some index as we arrive at r1 twice, we know that taking a step from rk takes it to r1, i.e. r1=rk+x or r1=rk−y. However, at any index it is clear that we can only arrive by one type of moves, since then 1≤r−x≤l−x and l−x<r+y≤l are both satisfied by r so 1+x≤r≤l−y, contradiction as l=x+y−1. So the index preceding r1 is also repeated at rk as they cannot be different. So necessarily all indices repeat. But the index preceding the second time we reach x cannot be 0=x−x and also cannot be x+y=l+1, contradiction. So we can never take infinitely many such steps.