title: How to exchange values between specific keys in a dictionary?
body: <p>Let's say you have a dictionary like this:</p>
  
  <pre><code>d = {
      'A': 'content_for_A',
      'B': 'content_for_B'
  }
  </code></pre>
  
  <p>What is the most efficient way to swap the values between the two entries? So the result should be like this:</p>
  
  <pre><code>d = {
      'A': 'content_for_B',
      'B': 'content_for_A'
  }
  </code></pre>
  
  <p>Of course, you can create a new dictionary <code>d2</code> and do <code>d2['A'] = d['B']; d2['B'] = d['A']</code> but is this the recommended way or is there an efficient way without the need to create a new dictionary?</p>