title: Check if dict values exist as keys in another dict
body: <p>I have two dictionaries:</p>
  
  <pre><code>concave = {6: [2, 3, 4, 5], 2: [6], 3: [6], 4: [6], 5: [6]}
  convex = {1: [2, 3, 4, 5], 2: [1, 3, 5], 3: [1, 2, 4], 4: [1, 3, 5], 5: [1, 2, 4], 6: [7, 8, 9, 10], 7: [6, 8, 10, 11], 8: [6, 7, 9, 11], 9: [6, 8, 10, 11], 10: [6, 7, 9, 11], 11: [7, 8, 9, 10]}
  </code></pre>
  
  <p>And I have returned the keys which have max length values in the convex dict:</p>
  
  <pre><code>max_lens = [1, 6, 7, 8, 9, 10, 11]
  </code></pre>
  
  <p>For each number in <code>max_lens</code>, I want to check that it does not exist as a key in <code>concave</code> <strong>and</strong> its <em>values</em> in <code>convex</code> exist as keys in <code>concave</code>. </p>
  
  <p>So in this example, '1' would satisfy this condition as it is not included in <code>concave</code> as a key, but its values in <code>convex</code> are (i.e. 2, 3 4 and 5).</p>
  
  <p>I have tried to figure out how to go about this using for loops/if statements:</p>
  
  <pre><code>for i in enumerate(max_lens):
      if i not in concave:
          for k,v in convex.items():
              for j in v:
  </code></pre>
  
  <p>That is about as far as I got before getting totally confused. There must be an easier way to do this other than using multiple for loops and if statements?</p>
  
  <p>I'm a bit of a python noob so sorry if this comes across as confusing!</p>