[b]8.[/b] Find all integers $a>1$ for which the least (integer) solution $n$ of the congruence $a^{n} \equiv 1 \pmod{p}$ differs from 6 (p is any prime number). [b](N. 9)[/b]
1. We start by considering the congruence \(a^n \equiv 1 \pmod{p}\) and the condition that the least integer solution \(n\) differs from 6. This implies that the order of \(a\) modulo \(p\), denoted \(\text{ord}_p(a)\), is not 6.

2. We factorize \(a^6 - 1\) as follows:
   \[
   a^6 - 1 = (a-1)(a+1)(a^2 + a + 1)(a^2 - a + 1)
   \]
   If \(p\) divides \(a^6 - 1\), then \(p\) must divide one of these factors.

3. We analyze the cases where \(p\) divides one of the first three factors:
   - If \(p\) divides \(a-1\), then \(a \equiv 1 \pmod{p}\) and \(\text{ord}_p(a) = 1\).
   - If \(p\) divides \(a+1\), then \(a \equiv -1 \pmod{p}\) and \(\text{ord}_p(a) = 2\).
   - If \(p\) divides \(a^2 + a + 1\), then \(\text{ord}_p(a) = 3\).

   In any of these cases, \(\text{ord}_p(a)\) is either 1, 2, or 3, which are all less than 6. Therefore, if \(p\) divides any of these factors, we are done.

4. We now consider the case where \(p\) divides \(a^2 - a + 1\). For such primes \(p\), we must have \(p\) dividing one of the first three factors, as otherwise \(\text{ord}_p(a) = 6\), which contradicts the problem's condition.

5. We perform a case analysis to find such primes \(p\):
   - If \(p\) divides \(a^2 - a + 1\), then \(a^2 - a + 1 \equiv 0 \pmod{p}\).
   - This quadratic equation has discriminant \(\Delta = (-1)^2 - 4 \cdot 1 \cdot 1 = -3\). For the equation to have integer solutions modulo \(p\), \(-3\) must be a quadratic residue modulo \(p\).

6. We check the possible values of \(p\):
   - For \(p = 2\), \(a^2 - a + 1 \equiv 0 \pmod{2}\) simplifies to \(a^2 - a + 1 \equiv 1 \pmod{2}\), which is always true since \(a^2 - a\) is even.
   - For \(p = 3\), \(a^2 - a + 1 \equiv 0 \pmod{3}\) simplifies to \(a^2 - a + 1 \equiv 0 \pmod{3}\). This equation has solutions modulo 3.

7. Since \(a^2 - a + 1\) is always odd, \(p\) cannot be 2. Therefore, \(p = 3\).

8. We now solve \(a^2 - a + 1 = 3^k\) for some integer \(k\):
   - Rewrite the equation as \((2a - 1)^2 = 4 \cdot 3^k - 3\).
   - Clearly, \(3\) must divide \(2a - 1\). Let \(2a - 1 = 3m\) for some integer \(m\).
   - Substituting back, we get \((3m)^2 = 4 \cdot 3^k - 3\), which simplifies to \(9m^2 = 4 \cdot 3^k - 3\).

9. For \(k > 1\), this equation leads to a contradiction. Therefore, \(k = 1\):
   - For \(k = 1\), we have \(a^2 - a + 1 = 3\).
   - Solving \(a^2 - a - 2 = 0\), we get \(a = 2\) (since \(a > 1\)).

10. For \(a = 2\), we check \(a^6 - 1 = 2^6 - 1 = 63 = 3^2 \cdot 7\):
    - Since \(2^2 - 1 = 3\) and \(2^3 - 1 = 7\), it satisfies our hypothesis.

Conclusion:
\(\boxed{a = 2}\) is the only integer greater than 1 for which the least integer solution \(n\) of the congruence \(a^n \equiv 1 \pmod{p}\) differs from 6.