My code :
'''
Content of Hello.txt is only -> \251
Actually \251 represents ©
'''
prefix = "PREFIX"
suffix = "SUFFIX"
f = open('Hello.txt')
d = f.read()
f.close()
print prefix+d+suffix
My Problem is,this prints PREFIX\251SUFFIX but I actually want it to print PREFIX©SUFFIX
As per How to convert octal escape sequences with Python I tried to d.decode('utf-8'), But still the same problem.