Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- data = []
- with open('file_src.py', 'r') as f:
- for line in f.readlines():
- data.append(line)
- #
- # process the data
- #
- with open('dest_file.py', 'w') as f:
- f.writelines(data)
- # or
- # write_data = ''.join(data)
- # with open('dest_file.py', 'w') as f:
- # f.writelines(write_data )
Add Comment
Please, Sign In to add comment