Skip to content

Commit

Permalink
Merge pull request #31 from Mathics3/sort_connected_components
Browse files Browse the repository at this point in the history
sort_connected_components
  • Loading branch information
rocky authored Aug 3, 2024
2 parents 8f1fe3c + 8d5f1da commit fa50659
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pymathics/graph/components.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def eval(
if graph.G.is_directed()
else nx.connected_components
)
components = [to_mathics_list(*c) for c in connect_fn(graph.G)]
components = [to_mathics_list(*sorted(c)) for c in connect_fn(graph.G)]
return ListExpression(*components)


Expand Down

0 comments on commit fa50659

Please sign in to comment.