Number S can be written as:
S = 15 + a + 18 + b + 30,
with all the addends in ascending order and different from each other.
What values can a and b take knowing that S is a perfect square?
Hint Number S lies in between which two numbers? Consider first the values in between which addends a and b must lie!