ENHANCE: Assignment 7 code