一:数组转化为字符串
法一
arr = [1, 2, 3]
# 这里的str()是函数
str2 = ''.join(str(i) for i in arr)
print(str2)
法二
str3 = ''
seq4 = [1, 2, 3]
seq5 = []
for i in range(len(seq4)):
seq5.append(str(seq4[i]))
# print(str3.join(seq5))
print(seq4)
print(str3.join(str(i) for i in seq5))
str6 = str3.join(str(i) for i in seq5)
print(str6)
二:字符串转化为数组