Refactoring: move all the graph stuff to a separate class, remove unnecessary variables and parameters, clean up the code #9
Add anoter test to be implemented