Parts a and b done