added assignment1 code