title: Returning a string in python
body: <p>I need to get a string returned to the calling function of a script. A module called 'utils' has the function being called for a return value. Trying to learn how exactly this works/what should be expected. An explanation would be great.   </p>
  
  <p>utils module function:</p>
  
  <pre><code>def test_return():
      some = 'nice'
      print some
  
      return some
  </code></pre>
  
  <p>the caller script just need to print the return string. It's just a print statement:</p>
  
  <pre><code>print utils.test_return
  </code></pre>
  
  <p>Actual result:
  <code>&lt;function test_return at 0x7f9cff9d8a28&gt;</code></p>
  
  <p>Expected result:
  <code>nice</code></p>