title: Writing a 'print' function in Python
body: <p>I want to create a function that works like the build-in print function in Python:</p>
  
  <pre><code>print 'test', i, 'started'
  </code></pre>
  
  <p>So a call like this should work:</p>
  
  <pre><code>log('test', i, 'started)
  </code></pre>
  
  <p>The log function should call the logging.info() function (from the Python logging module). How can I create such a function? </p>
  
  <p>This is my first try:</p>
  
  <pre><code>import logging
  def log(*args):
      logging.info(args)
  
  log('test', i, 'started)
  </code></pre>
  
  <p>But the output is not what I want:</p>
  
  <pre><code>('test', 2, 'started')
  </code></pre>
  
  <p>While it should be:</p>
  
  <pre><code>test 2 started
  </code></pre>