finished lab2 but need to debug