Completed version of week 2 assignment.