code: def cycle_graph(n, create_using=None):
      """Returns the cycle graph $C_n$ of cyclically connected nodes.
  
      $C_n$ is a path with its two end-nodes connected.
  
      .. plot::
  
          >>> nx.draw(nx.cycle_graph(5))
  
      Parameters
      ----------
      n : int or iterable container of nodes
          If n is an integer, nodes are from `range(n)`.
          If n is a container of nodes, those nodes appear in the graph.
          Warning: n is not checked for duplicates and if present the
          resulting graph may not be as desired. Make sure you have no duplicates.
      create_using : NetworkX graph constructor, optional (default=nx.Graph)
         Graph type to create. If graph instance, then cleared before populated.
  
      Notes
      -----
      If create_using is directed, the direction is in increasing order.
  
      """
      _, nodes = n
      G = empty_graph(nodes, create_using)
      G.add_edges_from(pairwise(nodes, cyclic=True))
      return G
  
imports: import itertools
  import numbers
  import networkx
  from networkx.classes import Graph
  from networkx.exception import NetworkXError
  from networkx.utils import nodes_or_number, pairwise
label_desc: Use image node_id 9 for calling a global function with example usage: cycle_graph(n, create_using) and returns: G