title: Convert unicode codepoint to UTF8 hex in python
body: <p>I want to convert a number of unicode codepoints read from a file to their UTF8 encoding.</p>
  
  <p>e.g I want to convert the string <code>'FD9B'</code> to the string <code>'EFB69B'</code>.</p>
  
  <p>I can do this manually using string literals like this:</p>
  
  <pre><code>u'\uFD9B'.encode('utf-8')
  </code></pre>
  
  <p>but I cannot work out how to do it programatically.</p>