You can put this solution on YOUR website! Weight = (1/m + a) + (m/n - b) oz.
= (1/m + am/m) + (m/n - bn/n)
= (am+1)/m + (m - bn)/n oz
------------
If this is some practical problem, no homework, it makes no sense.
It's just algebraic manipulation.
Something is missing.