edits to problem 4