this is more of my CS 1332 homework