Vanilla solution for HW2