How to print a list in one line with Python

1 Answer

0 votes
lst = ['python', 'java', 'c#', 'c', 'c++']

for s in lst:
    print(s, end=" ")

'''
run:

python java c# c c++

'''

 



answered Mar 25, 2017 by avibootz

Related questions

1 answer 270 views
2 answers 356 views
1 answer 260 views
1 answer 293 views
2 answers 251 views
...