摘要: 使用map函数 python3.x,map返回的是map对象,当然也可以转换为List: list1 = list(map(int, list1)) 输入时去除空格元素: list1 = list(input().split(' ')) 列表去除空格元素: list1 = [x for x in l 阅读全文
posted @ 2020-04-30 16:40 Y鱼鱼鱼Y 阅读(790) 评论(0) 推荐(0)