lab2 code finished'