python 讀取TXT內內容,按行存入list

def ReadTxtName(rootdir): lines = [] with open(rootdir, 'r') as file_to_read: while True: line = file_to_read.readline() if not line: break
相關文章
相關標籤/搜索