addVertex

abstract fun addVertex(value: T): Graph<T>

Adds a vertex to the graph.

Return

a new graph instance with the vertex added

Parameters

value

the value of the vertex to add