Condition that two finite sequences with different indices are equal (Lemma 0A, Enderton) Ref to Herbert Enderton, A Mathematical Introduction to Logic (2nd - 2001).
The statement that I am questioning is : 
Lemma 0A [page 4] : Assume that $\langle x_1,\ldots,x_m\rangle = \langle y_1,\ldots,y_m,\ldots,y_{m+k}\rangle$. Then $x_1=\langle y_1,\ldots,y_{k+1}\rangle$.
However, I don't understand why $x_1$ necessarily has to be equal to $\langle y_1,\ldots,y_{k+1}\rangle$. Why could it not be that $x_1=y_1$ and $x_2=\langle y_2,\ldots,y_{k+2}\rangle$?
 A: The reason is that the sequence $\langle x_1 \ldots,x_{n+1} \rangle$ is defined recursively [see page 4] as an ordered $(n+1)$-uple :

$\langle \langle x_1, \ldots,x_n \rangle, x_{n+1} \rangle$.

Thus, intuitively, if :

$\langle \langle x_1,\ldots,x_{m-1} \rangle, x_m \rangle = \langle \langle y_1,\ldots, y_{m-1+k} \rangle, y_{m+k} \rangle$

by property of ordered pair (i.e. $\langle x,y \rangle=\langle u,v \rangle$ iff $x=u$ and $y=v$) we can "equate" the two left-components.
If we repeat the operation $m-1$ times, until only $x_1$ is left, we end with : $\langle x_1 \rangle = \langle y_1, \ldots, y_l \rangle$, where $l=(m+k)-(m-1)$, i.e. $l=k+1$; thus :

$x_1 = \langle y_1, \ldots,y_{k+1} \rangle$. 


The proof is by induction on the number $m$ of "terms" of the LHS sequence.
Basis
When $m=1$, we have simply to write down the two sequences. If $\langle x_1 \rangle =\langle y_1, \ldots,y_{k+1} \rangle$, clearly $x_1= \langle x_1 \rangle$; thus :

$x_1 = \langle y_1, \ldots,y_{k+1} \rangle$

Induction step
Assume (induction hypotheses) that the lemma holds for $m$, i.e.

if $\langle x_1,\ldots,x_m \rangle = \langle y_1,\ldots, y_{m+k} \rangle$, then $x_1 = \langle y_1,\ldots,y_{k+1} \rangle$. 

We have to prove that it holds for $m+1$, i.e. that

if $\langle x_1,\ldots,x_{m+1} \rangle = \langle y_1,\ldots, y_{m+1+k} \rangle$, then $x_1 = \langle y_1,\ldots,y_{k+1} \rangle$. 

But what is $\langle x_1,\ldots,x_{m+1} \rangle$ ? it is an ordered pair : $\langle \langle x_1,\ldots,x_m \rangle, x_{m+1} \rangle$.
And the same for $\langle y_1,\ldots, y_{m+1+k} \rangle$, which is $\langle\langle y_1,\ldots, y_{m+k} \rangle, y_{m+1+k} \rangle$. 
Thus, by the fundamental property of ordered pairs we have that the two "left-components" must be equal, i.e.

$\langle x_1,...,x_m \rangle = \langle y_1,..., y_{m+k} \rangle$.

Then we can apply induction hypotheses to conclude that :


$x_1 = \langle y_1,...,y_{k+1} \rangle$. 


