title: Combining 2 python lists of dictionaries
body: <p>I have 2 python list of dictionaries. First python list looks like below : </p>
  
  <pre><code>l1=  [{'compu_method': 'ROTACC', 'aufloesung': '1024'}, 
  {'compu_method': 'TMPOUTS', 'aufloesung': '1'}]
  </code></pre>
  
  <p>Second python list looks like this:</p>
  
  <pre><code>l2=  [{'signal_name': 'XXXX', 'compu_method': 'ROTACC', 'min_wert': '-500', 'max_wert': '500'},
   {'signal_name': 'YYYY', 'compu_method': 'TMPOUTS', 'min_wert': '-70', 'max_wert': '184'}, 
   {'signal_name': 'ZZZZ', 'compu_method': 'TMPOUTS', 'min_wert': '-70', 'max_wert': '184'}]
  </code></pre>
  
  <p>Both lists have <strong>compu_method</strong> common. I want <strong>aufloesung</strong> from first list for all the <strong>compu_method</strong>  which exists in second list. 
  I would like to have a final list like this : </p>
  
  <pre><code>[{'signal_name': 'XXXX', 'compu_method': 'ROTACC', 'min_wert': '-500', 'max_wert': '500','aufloesung': '1024'},
   {'signal_name': 'YYYY', 'compu_method': 'TMPOUTS', 'min_wert': '-70', 'max_wert': '184','aufloesung': '1'}, 
   {'signal_name': 'ZZZZ', 'compu_method': 'TMPOUTS', 'min_wert': '-70', 'max_wert': '184','aufloesung': '1'}]
  </code></pre>
  
  <p>I tried below code but it doesnt give the desired output: </p>
  
  <pre><code>from collections import defaultdict
  d = defaultdict(dict)
  for l in (l1, l2):
      for elem in l:
          d[elem['compu_method']].update(elem)
  
  l3 = d.values()
  print(l3)
  </code></pre>
  
  <p>What modification is needed in the code?</p>