Check primality and Fermat's condition for given values
Enter values for p and a to test if:
p is prime (using the AKS primality test).p is prime and not divisible by a, then Fermat's Little Theorem states: a^(p-1) ≡ 1 (mod p).Fermat's Little Theorem states that if p is a prime number and a is any integer not divisible by p, then: