Skip to content

Addition of path reconstruction for every implementation #5

@rvcgeeks

Description

@rvcgeeks

Hi Diogo,
Can you please add path reconstruction for all implementations, currently you are displaying only distances of shortest paths for all edges from single source.

For eg:

digraph G {
  A -> B [label=3];
  A -> C [label=6];
  B -> C [label=4];
  B -> D [label=4];
  C -> D [label=8];
  C -> E [label=3];
  D -> E [label=2];
  D -> F [label=5];
  E -> F [label=1];
  E -> G [label=7];
  F -> H [label=2];
  G -> H [label=3];
}

Output:

Source: A

To A: dist=0  path=A
To B: dist=3  path=A -> B
To C: dist=6  path=A -> C
To D: dist=7  path=A -> B -> D
To E: dist=9  path=A -> B -> D -> E
To F: dist=10  path=A -> B -> D -> E -> F
To G: dist=16  path=A -> B -> D -> E -> G
To H: dist=12  path=A -> B -> D -> E -> F -> H

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions