Skip to main content
`Ctrl`+`K`

# generate_multiline_adjlist

generate_multiline_adjlist(G, delimiter=' ')

  Generate a single line of the graph G in multiline adjacency list format.

  Parameters:
    G NetworkX graph
    delimiter string, optional

      Separator for node labels

  Returns:
    lines string

      Lines of data in multiline adjlist format.

  See also

  `write_multiline_adjlist`, `read_multiline_adjlist`

  Examples

      >>> G = nx.lollipop_graph(4, 3)
      >>> for line in nx.generate_multiline_adjlist(G):
      ...     print(line)
      0 3
      1 {}
      2 {}
      3 {}
      1 2
      2 {}
      3 {}
      2 1
      3 {}
      3 1
      4 {}
      4 1
      5 {}
      5 1
      6 {}
      6 0