finished the initial part of assignment 6