Homework 1-2, attempt 1