Assignment 2 Derive Solution