title: Are two graphs isomorphic in python, no imports
body: <p>I am writing a function <code>is_iso(graph1, graph2)</code> that takes in two graphs as its input, and then determines whether or not the two graphs are isomorphic. </p>
  
  <p>I can assume that the two graphs will have the same number of vertices and that the names used on the vertices will be the same.</p>
  
  <p><code>is_iso({“A” : [“B”, “C”], “B” : [“A”], “C” : [“A”]}, {“A” : [“B”], “B” : [“A”, “C”], “C” : [“B”]})</code> should return <code>True</code></p>
  
  <p><code>is_iso({“A” : [“B”, “C”], “B” : [“A”, “C”], “C” : [“A”, “B”]}, {“A” : [“B”, “C”], “B” : [“A”], “C” :[“A”]})</code> should return <code>False</code></p>
  
  <pre><code>def is_iso(graph1,graph2):
      for vertex in graph1:#loops through every vertex in graph1 
           seq1 += [len(graph1[vertex])]#adds the degree of each vertex to the list
  
      for vertex in graph2: #loops through every vertex in graph2 
          seq2 += [len(graph2[vertex])]#adds the degree of each vertex to the list
  
      return sorted(seq1) == sorted(seq2) 
  </code></pre>
  
  <p>All my method currently checks if the degree sequence is the same but graphs can have the same degree sequence and not be isomorphic. I am not sure how to finish checking from here. I am not allowed to import any libraries. Any help is greatly appreciated!</p>