Homework 6 for cs193p (iPhone Development)