code: def ellipsize(s, max_length=60):
      
      if len(s) > max_length:
          ellipsis = '...'
          return s[:(max_length - len(ellipsis))] + ellipsis
      else:
          return s
docs: >>> print(ellipsize(u'lorem ipsum dolor sit amet', 40))
      lorem ipsum dolor sit amet
      >>> print(ellipsize(u'lorem ipsum dolor sit amet', 20))
      lorem ipsum dolor...