The product of two positive integers minus their sum is 39. The integers are relatively prime, and each is less than 2. What is the sum of the two integers?