switches vector<Node> to vector<Node*>. Now all nodes are dealt by points to Nodes stored in heap with addresses in Graph::vector<Node*> nodes