title: Create json query string in python from a list of json name
body: <p>I have a JSON object like this:</p>
  <pre class="lang-py prettyprint-override"><code>a = {'s1':12134,'s2':{'s3':678,'s4':'blah','s5':'sample'}}
  </code></pre>
  <p>and list of its keys:</p>
  <pre class="lang-py prettyprint-override"><code>l = ['s2','s3']
  </code></pre>
  <p>How do I query <code>s3</code> value dynamically using the list <code>l</code>? Basically using the list I want to create Python code as follows:</p>
  <pre><code>a[l[0]][l[2]]
  </code></pre>
  <p>which will return the value <code>678</code>. How can create the above statement using the list <code>l</code>?</p>