# 2017 AIME I Problems/Problem 2

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

## Problem 2

When each of $702$, $787$, and $855$ is divided by the positive integer $m$, the remainder is always the positive integer $r$. When each of $412$, $722$, and $815$ is divided by the positive integer $n$, the remainder is always the positive integer $s \neq r$. Find $m+n+r+s$.

## Solution

Let's tackle the first part of the problem first. We can safely assume: $$702 = xm + r$$ $$787 = ym + r$$ $$855 = zm + r$$ Now, if we subtract two values: $$787-702 = 85 = 17\cdot5$$ which also equals $$(ym+r)-(xm+r) = m\cdot(y-x)$$ Similarly, $$855-787 = 68 = 17\cdot4; (zm+r)-(ym+r) = m\cdot(z-y)$$ Since $17$ is the only common factor, we can assume that $m=17$, and through simple division, that $r=5$.

Using the same method on the second half: $$412 = an + s$$ $$722 = bn + s$$ $$815 = cn + s$$ Then. $$722-412 = 310 = 31\cdot10; (bn+s)-(an+s) = n\cdot(b-a)$$ $$815-722 = 93 = 31\cdot3; (cn+s)-(bn+s) = n\cdot(c-b)$$ The common factor is $31$, so $n=31$ and through division, $s=9$.

The answer is $m+n+r+s = 17+31+5+9 = \boxed{062}$