What are the divisors of 4270?

1, 2, 5, 7, 10, 14, 35, 61, 70, 122, 305, 427, 610, 854, 2135, 4270

8 even divisors

2, 10, 14, 70, 122, 610, 854, 4270

8 odd divisors

1, 5, 7, 35, 61, 305, 427, 2135

How to compute the divisors of 4270?

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 4270 by each of the numbers from 1 to 4270 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)

  • 4270 / 1 = 4270 (the remainder is 0, so 1 is a divisor of 4270)
  • 4270 / 2 = 2135 (the remainder is 0, so 2 is a divisor of 4270)
  • 4270 / 3 = 1423.3333333333 (the remainder is 1, so 3 is not a divisor of 4270)
  • ...
  • 4270 / 4269 = 1.0002342468962 (the remainder is 1, so 4269 is not a divisor of 4270)
  • 4270 / 4270 = 1 (the remainder is 0, so 4270 is a divisor of 4270)

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 4270 (i.e. 65.345237010818). 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 )

  • 4270 / 1 = 4270 (the remainder is 0, so 1 and 4270 are divisors of 4270)
  • 4270 / 2 = 2135 (the remainder is 0, so 2 and 2135 are divisors of 4270)
  • 4270 / 3 = 1423.3333333333 (the remainder is 1, so 3 is not a divisor of 4270)
  • ...
  • 4270 / 64 = 66.71875 (the remainder is 46, so 64 is not a divisor of 4270)
  • 4270 / 65 = 65.692307692308 (the remainder is 45, so 65 is not a divisor of 4270)