Modified the graph classes a bit. Tried to implement graph constructing but it didn't work out as planned.