Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Following up on vdelecroix's comment above, here's an example:

sage: G=graphs.PathGraph(5)
sage: G.distance(2,4)
2