CS322 Assignment 3