In this how they have got that term in the solution .
$K \propto 1/m$
$K_1 = \frac{1/m_1}{1/m_1 + 1/m_2} \times K_{tot}= \frac{m_2}{m_1 + m_2} K_{tot}$.