<s>[INST] Why is: $1+2+2^2+\cdots+2^{n-2} = 2^{n-1}-1$? I know that this might be elementary, but I don't know how to prove this equality, some hint?
I tried to extract the common two:
$$ 1 + 2^1+2^2 + \cdots + 2^{n-2} = 1 + 2(1+2+\cdots+2^{n-3}) $$
But this didn't help 
 [/INST] The sum $1+2+2^2+\cdots+2^{n-2} $ doesn't change if we multiply it by $1$ i.e. $2-1$:
\begin{eqnarray}1+2+2^2+\cdots+2^{n-2} &=& (1+2+2^2+\cdots+2^{n-2})(2-1)\\
&=& (\color{red}{2+2^2+2^3+\cdots+2^{n-2}}+2^{n-1})-(1+\color{red}{2+2^2+2^3+\cdots+2^{n-2}})\\
&=&2^{n-1}-1
\end{eqnarray}
</s>