i really don't know if this is correct, however, this is my idea (at least for part a).

if p is not prime, then at least is not an integral domain since where for some m,n both not units (or not equal to 1) and hence have zero divisors. Note that by taking , thus cannot be an integral domain.