What are the divisors of 3434?

1, 2, 17, 34, 101, 202, 1717, 3434

4 even divisors

2, 34, 202, 3434

4 odd divisors

1, 17, 101, 1717

How to compute the divisors of 3434?

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

  • 3434 / 1 = 3434 (the remainder is 0, so 1 is a divisor of 3434)
  • 3434 / 2 = 1717 (the remainder is 0, so 2 is a divisor of 3434)
  • 3434 / 3 = 1144.6666666667 (the remainder is 2, so 3 is not a divisor of 3434)
  • ...
  • 3434 / 3433 = 1.0002912904165 (the remainder is 1, so 3433 is not a divisor of 3434)
  • 3434 / 3434 = 1 (the remainder is 0, so 3434 is a divisor of 3434)

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 3434 (i.e. 58.600341295934). 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 )

  • 3434 / 1 = 3434 (the remainder is 0, so 1 and 3434 are divisors of 3434)
  • 3434 / 2 = 1717 (the remainder is 0, so 2 and 1717 are divisors of 3434)
  • 3434 / 3 = 1144.6666666667 (the remainder is 2, so 3 is not a divisor of 3434)
  • ...
  • 3434 / 57 = 60.245614035088 (the remainder is 14, so 57 is not a divisor of 3434)
  • 3434 / 58 = 59.206896551724 (the remainder is 12, so 58 is not a divisor of 3434)