title: How to update values in nested dictionary if keys are in a list?
body: <p>Let's say i have a list of keys</p>
  
  <pre><code>key_lst = ["key1", "key2", "key3"]
  </code></pre>
  
  <p>and i have a value</p>
  
  <pre><code>value = "my_value"
  </code></pre>
  
  <p>and an example dict <code>my_dict</code> with this structure</p>
  
  <pre><code>{
  "key1": {
      "key2": {
          "key3": "some_value"
          }
      },
  }
  </code></pre>
  
  <p>How can I dynamically assign the new value in variable <code>value</code> to <code>my_dict["key1"]["key2"]["key3"]</code> by going thru / looping over my <code>key_lst</code>?</p>
  
  <p>I can not just say <code>my_dict["key1"]["key2"]["key3"] = value</code> since the keys and the number of keys is changing. I always get the keys (the path that i have to save the value at) in a list...</p>
  
  <p>The output I am looking for is <code>{'key1': {'key2': {'key3': 'my_value'}}}</code>. The dictionary structure is predefined.</p>
  
  <p>I'm using Python 3.7</p>