edited assignment2, attempt to 3