A prime number is a number with exactly two positive factors: $1$ and itself.
To check if a number like $31$ is prime, test whether it can be divided evenly (no remainder) by any whole number other than $1$ and $31$. If no such number exists, then $31$ is prime.
What Is A Prime Number?
A number $n$ is prime if:
$$ \text{Factors of } n = {1, n} $$
If any number between $2$ and $\sqrt{n}$ divides $n$ exactly, then $n$ is not a prime number.
Step-by-Step: Is 31 Prime?
We check all whole numbers from $2$ up to $\lfloor \sqrt{31} \rfloor = 5$.
Try 2:
$$ 31 \div 2 = 15.5 \quad \text{(not a whole number)} $$
Try 3:
$$ 31 \div 3 \approx 10.33 \quad \text{(not a whole number)} $$
Try 4:
$$ 31 \div 4 = 7.75 \quad \text{(not a whole number)} $$
Try 5:
$$ 31 \div 5 = 6.2 \quad \text{(not a whole number)} $$
We’ve reached the square root of $31$ and found no factors other than $1$ and $31$.
✅ Therefore, $31$ has only two factors.
Final Answer
The number $31$ is a prime number.