python:列表中是字符串,想把字符串按指定符号分割,列表内容变成分割后的字符串列表

代码:

transactions=[i.split(",") for i in transactions]

测试:

在这里插入图片描述

原创文章 397 获赞 284 访问量 1万+

猜你喜欢

转载自blog.csdn.net/weixin_42721412/article/details/105665048