Given that the combined average is M+F, hence
(M+F)=(2MF+42){(M+F)+1}
Or (M+F)2+(M+F)=2MF+42
Or M2+F2+M+F=42
Or M(M+1)+F(F+1)=42, since M and F are integers, there is only one possibility that M(M+1) =12 or 30 and F(F+1) =30 or 12. Hence M can be 3 or 5 and F can be 5 or 3. So the sum of M and F is 8.