This is a program to change the unicode symbols to their respective entities from file x.input and the output should be placed in y.output. However, the program doesn't do that and only creates a copy of the file.
I have both Python27 and 35 displaying this issue and the platform is Win 7.
Where am I going wrong? Please help.
#!/usr/bin/env python
# -*- coding: utf-8 -*-
#import io
f1 = open('x.input').read()
f2 = open('y.output','w')
for line in f1:
x = line.replace('“', '“')
f2.write(x)
#f1.close()
f2.close()
A screenshot of the entire program: Actual program with the double quote which is creating issues