almost finish assignment1