Let $p$ be an odd prime number when $p-1=2^{s}\cdot t$, $s\in \mathbb{N}, t\in \mathbb{Z}$ and $t $ is odd. Need to prove that if $(a,p)=1$, then $a^{t}\equiv 1 \pmod{p}$ or $a^{2^{i}\cdot t}\equiv -1 \pmod{p}$, for $0\le i\le s-1$. In addition $a\in \mathbb{Z^{+}}$.
My attempt: suppose that $(a,p)=1$ and $p-1=2^{s}\cdot t$. Since $0\le i\le s-1$ then let $s=i+x$, for $x\in \mathbb{N}$. According to little's Fermat theorem, since $(a,p)=1$ we have that: $a^{p-1}\equiv 1 \pmod{p}$. Recall that $p-1=2^{s}\cdot t$ so by substitution - $a^{p-1}\equiv a^{2^{s}\cdot t}\equiv 1 \pmod{p}$. Now by substitution of $s=i+x$ we get: $a^{2^{i}\cdot 2^{x}\cdot t}\equiv (a^{2^{i}\cdot 2^{x}})^{t}\equiv (a^{2^{i}\cdot t})^{2^{x}}\equiv 1 \pmod{p}$. From here I don't know how to proceed, but I still didn't use the definition of t and p being odd prime numbers. Therefore I will be glad to get some help. Thanks!