NOTE: the latest version is 1.2.0
Your graph is defined by a type a and a function that give the next element in the graph, if any. isCycle tells you wether the graph is a cycle.
a
isCycle
Takes a function that gives the possible next element in the graph and the first element, returns True if the graph is a cycle
Takes a function that gives the possible next element in the graph and the first element, returns True if the graph is a cycle