with open txt python读取txt 去除换行符

with open("users.txt", "r", encoding='utf-8') as f:
    f = f.read().splitlines()
    print(f)
with open txt python读取txt 去除换行符_第1张图片

你可能感兴趣的:(python实战100例,python)