Fixed bug where topoSort was incorrect (a while loop was in the wrong place).
Implemented user input of nodes.