Answer
a. $7$
b. $1$
Work Step by Step
$$n=dq+r=d(n\ div\ d)+n\ mod\ d$$
$$50=9(50\ div\ 7)+50\ mod\ 7=7(7)+1$$
The numbers $n\ div\ d$ and $n\ mod\ d$ are defined to be the numbers $q$ and $r$, respectively, as given in the quotient-remainder theorem. See page 181 of the text.