Trying to print the graph