What are the divisors of 492?

1, 2, 3, 4, 6, 12, 41, 82, 123, 164, 246, 492

8 even divisors

2, 4, 6, 12, 82, 164, 246, 492

4 odd divisors

1, 3, 41, 123

How to compute the divisors of 492?

A number N is said to be divisible by a number M (with M non-zero) if, when we divide N by M, the remainder of the division is zero.

N mod M = 0

Brute force algorithm

We could start by using a brute-force method which would involve dividing 492 by each of the numbers from 1 to 492 to determine which ones have a remainder equal to 0.

Remainder = N ( M × N M )

(where N M is the integer part of the quotient)

  • 492 / 1 = 492 (the remainder is 0, so 1 is a divisor of 492)
  • 492 / 2 = 246 (the remainder is 0, so 2 is a divisor of 492)
  • 492 / 3 = 164 (the remainder is 0, so 3 is a divisor of 492)
  • ...
  • 492 / 491 = 1.0020366598778 (the remainder is 1, so 491 is not a divisor of 492)
  • 492 / 492 = 1 (the remainder is 0, so 492 is a divisor of 492)

Improved algorithm using square-root

However, there is another slightly better approach that reduces the number of iterations by testing only integers less than or equal to the square root of 492 (i.e. 22.181073012819). Indeed, if a number N has a divisor D greater than its square root, then there is necessarily a smaller divisor d such that:

D × d = N

(thus, if N D = d , then N d = D )

  • 492 / 1 = 492 (the remainder is 0, so 1 and 492 are divisors of 492)
  • 492 / 2 = 246 (the remainder is 0, so 2 and 246 are divisors of 492)
  • 492 / 3 = 164 (the remainder is 0, so 3 and 164 are divisors of 492)
  • ...
  • 492 / 21 = 23.428571428571 (the remainder is 9, so 21 is not a divisor of 492)
  • 492 / 22 = 22.363636363636 (the remainder is 8, so 22 is not a divisor of 492)