title: Split a string into pieces of max length X - split only at spaces
body: <p>I have a long string which I would like to break into pieces, of max X characters. BUT, only at a space (if some word in the string is longer than X chars, just put it into its own piece).</p>
  
  <p>I don't even know how to begin to do this  ... Pythonically</p>
  
  <p>pseudo code:</p>
  
  <pre><code>declare a list
  while still some string left:
     take the fist X chars of the string
     find the last space in that
     write everything before the space to a new list entry
     delete everything to the left of the space
  </code></pre>
  
  <p>Before I code that up, is there some python module that can help me (I don't think that <a href="http://pymotw.com/2/pprint/" rel="noreferrer">pprint</a> can)?</p>