Update graph.java