Solution
Part a.
Part b.