The gravitational field due to a spherical shell of matter (or equivalently, the electric field due to a spherical shell of charge) is given by:
\begin{equation} \Vec g = \begin{cases}
0&\textrm{for } r<a\\ -G \,\frac{M}{b^3-a^3}\,
\left( r-\frac{a^3}{r^2}\right)\, \hat r & \textrm{for } a<r<b\\
\end{cases} \end{equation} (If you want extra practice with Gauss's law, this is a good question to practice on!)
This problem explores the consequences of the divergence theorem for this shell.