lab2 nearly working