newContents = ['The', 'crazy', 'panda', 'walked', 'to', 'the', 'Maulik', 'and', 'then', 'picked.', 'A', 'nearby', 'Ankur', 'was\n', 'unaffected', 'by', 'these', 'events.\n']
print(' '.join(newContents))
output:
The crazy panda walked to the Maulik and then picked. A nearby Ankur was
unaffected by these events.
there is space before the (first) word unaffected on second line I don't want a space there.