Update graph.hpp

added input()