I am looking to draw a graph knowing a simple adjacency representation of the graph like:
A = {{1, 3}, {2, 3}, {3, 4, 5}, {4, 5}, {5}}
Where A
is my Adjacency List. I was thinking I could use Graph[]
and maybe some kind of pattern matching:
Graph[{_\[DirectedEdge]_}]
I am also not familiar with patterns in mathematica (the "_" that gets used a lot but has been hard for me to understand).