Graph representation in Dr Scheme

Posted by John Retallack on Stack Overflow See other posts from Stack Overflow or by John Retallack
Published on 2010-05-03T21:12:50Z Indexed on 2010/05/03 21:18 UTC
Read the original article Hit count: 689

Filed under:
|
|

I want to represent a graph in Dr. Scheme in the following manner: For each node I want to store it's value and a list of adjacent nodes,the problem which i'm having difficulties with is that I want the adjacent nodes to be stored as references to other nodes.
For example: I want node ny to be stored as („NY“ (l p)) where l and p are adjacent nodes,and not as („NY“ („London“ „Paris“)).

© Stack Overflow or respective owner

Related posts about drscheme

Related posts about Scheme