Python how to remove last comma from print(string, end=“, ”)

前端 未结 5 1482
感动是毒
感动是毒 2021-01-13 05:40

my output from a forloop is

string = \"\"
for x in something:
   #some operation
   string =  x += string 

print(string)

5
66
777

I use

5条回答
提交回复
热议问题