Updated Homework 18