graphs for problem 1