How do I convert a list into a string with spaces in Python?

" ".join(my_list)

You need to join with a space, not an empty string.

Leave a Comment