lib/networkx/graph.rb
# Removes multiple edges from the graph
#
# @example
#   graph.remove_edges([%w[Noida Bangalore], %w[Bangalore Chennai]])
#
# @param edges [Array<Object>] the array of edges to be removed
Removes multiple edges from the graph
Removes multiple edges from the graph
def remove_edges(edges)
      case edges
      when Array, Set
        edges.each { |node_1, node_2| remove_edge(node_1, node_2) }
      else
        raise ArgumentError, 'Expected Arguement to be Array or Set of edges, '\
                             "received #{edges.class.name} instead."
      end
    end
def remove_edges ( edges ) case edges when Array , Set edges . each { | node_1 , node_2 | remove_edge ( node_1 , node_2 ) } else raise ArgumentError , 'Expected Arguement to be Array or Set of edges, ' "received #{edges.class.name} instead." end end
Removes multiple edges from the graph
Removes multiple edges from the graph
edges
the array of edges to be removed
the array of edges to be removed
example
graph.remove_edges([%w[Noida Bangalore], %w[Bangalore Chennai]])
graph . remove_edges ( [ %w [ Noida Bangalore ] %w [ Bangalore Chennai ]] )