def sort_edge(edges):
        """Sort iterable of edges first by left node indices then right.

        Args:
            edges(list[Edge]): List of edges to be sorted.

        Returns:
            list[Edge]: Sorted list by left and right node indices.
        """
        return sorted(edges, key=lambda x: (x.L, x.R))
def sort_edge ( edges ) : return sorted ( edges , key = lambda x : ( x . L , x . R ) )
Sort iterable of edges first by left node indices then right.

        Args:
            edges(list[Edge]): List of edges to be sorted.

        Returns:
            list[Edge]: Sorted list by left and right node indices.