+ 1

How to convert list into string

https://code.sololearn.com/c9Lt5ixvRap8/?ref=app This doesn't work

17th Aug 2020, 4:04 PM
Amit Kumar
Amit Kumar - avatar
3 Respostas
+ 2
Amit Kumar a = ['list', 'into', 'string'] b = ''.join(a) print(b) Output: 'listintostring' Note the delimiter before the .join(). It is used to dictate the seperator of the list item. b = ' '.join(a) print(b) Output: 'list into string' b = '-'.join(a) print(b) Output: 'list-into-string' Hope this helps clarify things 😃😃
17th Aug 2020, 4:54 PM
Tomiwa Joseph
Tomiwa Joseph - avatar
0
Tomiwa Joseph aah thank you for the clarification of ''✌️
18th Aug 2020, 11:02 AM
Amit Kumar
Amit Kumar - avatar