Homework 8 fixes