PwC Interview Question

To solve the CDD case