Added hw3 code