title: How to eval() a string in a dictionary Python2.7
body: <p>I have a dictionary:</p>
  
  <pre><code>key = {'K_z':'K_w'}
  </code></pre>
  
  <p>I want to get K_w as a value name instead of a string, I heard that the eval() function can convert strings to value names.</p>
  
  <p>But when I type:</p>
  
  <pre><code>print(eval(key['K_z']))
  </code></pre>
  
  <p>I get 'K_z' instead of having the K_w value.</p>
  
  <p>Can you help me ?</p>
  
  <p>If it helps, I'm using it for pygame to let the player change the key bindings, specially with AZERTY and QWERTY differences...</p>