Python list merges methods of concatenating strings

  • 2020-04-02 09:49:29
  • OfStack

So let's say I have a list


binfo = ['lao','wang','python']

We know from the help method that we can use the join method of string to solve this problem.

Here we use Spaces to connect the three words:


content = " ".join(binfo)
print content

The result: Lao wang python


Related articles: