title: Python: load variables in a dict into namespace
body: <p>I want to use a bunch of local variables defined in a function, outside of the function. So I am passing <code>x=locals()</code> in the return value. </p>
  
  <p>How can I load all the variables defined in that dictionary into the namespace outside the function, so that instead of accessing the value using <code>x['variable']</code>, I could simply use <code>variable</code>.</p>