str1 = "hi hello world" print(str1.split(" "))输出:['hi', 'hello', 'world']
l = ["hi","hello","world"] print(" ".join(l))输出:hi hello world
posted on 2019-12-05 16:32 骄傲的赛亚人 阅读(199) 评论(0) 收藏 举报
博客园 © 2004-2025 浙公网安备 33010602011771号 浙ICP备2021040463号-3