title: use route reference to edit nested dictionary in python
body: <p>From : <a href="http://connor-johnson.com/2015/02/28/generate-a-tree-structure-in-python/" rel="nofollow">http://connor-johnson.com/2015/02/28/generate-a-tree-structure-in-python/</a></p>
  
  <p>with :</p>
  
  <pre><code>places=[['US', 'Central', 'Louisiana', 'Monroe'], ['US', 'Central', 'Texas', 'Midland'], ['US', 'Pacific', 'California', 'East Palo Alto']]
  </code></pre>
  
  <p>I can build :</p>
  
  <pre><code>placesDict={'US': {'Central': {'Louisiana': {'Monroe': {}}, 'Texas': {'Midland': {}}}, 'Pacific': {'California': {'East Palo Alto': {}}}}}
  </code></pre>
  
  <p>now I have a list , <code>placesCode=['318','432','650 ']</code></p>
  
  <p>How to use 'places' and 'placesCode' as reference to retouch placesDict to :</p>
  
  <pre><code>placesDict={'US': {'Central': {'Louisiana': {'Monroe': '318'}, 'Texas': {'Midland': '432'}}, 'Pacific': {'California': {'East Palo Alto': '650'}}}}
  </code></pre>
  
  <p>Sincerely
  -bino-</p>