George,
I tried to implement a sample implementation with a simple DataStructure "NodeLink" to indicate "From" and "To" vertices of a link.
Following are the steps to approach this problem
1)Make an appropriate data structure to represent the graph, its vertices and node links.
2)Construct partial graphs for each entry in the nodelinks i.e all the vertices approachable from a given vertex.
3)Iterate through the partial graphs constructed to see if any node is visited more than once in a subgraph.
In the program below, I used a hastable to keep track of nodes and the number of times visited count. I would initialize the hashtable with "0 visit counts" for each partial graph.
I hope this helps!
-Praveena