Find four positive integers p,q,r and s such that:

- p*q*r*s= 8!, and:
- p*q+p+q = 524, and:
- q*r+q+r = 146, and:
- r*s+r+s = 104

Prove that there are no others.

By the way, if negative integers had been allowed, there would still be only one solution

a) p*q*r*s = 8!, so the only prime factors in these numbers are 7 and less.

b) Subtracting equation 4 from 3 and rearranging terms gives

(r+1)(q-s) = 42,

so if r is negative then (r+1) must be -1,-2,-3,-6,-7,-14,-21 or -42

This makes r = -2,-3,-4,-7,-8,-15,-22 or -43.

We can rule out -22 and -43 (prime factors are too large),

so r = -2,-3,-4,-7,-8, or -15

c) From equation 3, q = (146-r)/(1+r)

The possibilities are

r q

-- --

-2 -148 <== multiple of 37

-3 -74.5 <== not an integer

-4 -50 <== multiple of 25

-7 -25.5 <== not an integer

-8 -22 <== multiple of 11

-15 -11.5 <== not an integer

so, r must be positive, and the only solution is the one previously posted