Guest User

Untitled

a guest
Feb 5th, 2020
36
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import glob
  2. import os
  3. text = []
  4. file_path = 'filepath'
  5. for filename in glob.glob(os.path.join(file_path, '*.txt')):
  6.     with open(filename, 'r', encoding = "ISO-885901") as infile:
  7.         text.append(infile.read())
RAW Paste Data