Posting Assignment2 answer.

This is my code first draft.