Implement Vertex class and resolve #8