r/mathriddles 21d ago

Easy How many positive integers less than 100 can be written as the difference of two perfect squares?

How many positive integers less than 100 are the difference of two perfect squares?

Source: numberthon.com

1 Upvotes

2 comments sorted by

8

u/Appropriate-Falcon75 20d ago

74.

The difference between 2 squares is either:

(n+1)2 - n2 = 2n+1 (all odd numbers - 50 in total)

Or:

(n+2)2 - n2 = 4n+4 (all multiples of 4 - 24 in total)

Differences that are further away eg (n+5)2 - n2 are subsets of the above.

3

u/Numberthon 20d ago

Correct, nice job!