Homework 2 completed with extra credit