Is this what you want? py> s = 'This string contains two times - end' py> print s.replace(' ', ' '*6) This string contains two times - end see http://docs.python.org/lib/string-methods.html On Oct 30, 6:26 pm, "一首诗" <newpt... at gmail.com> wrote: > Is there any simple way to solve this problem?