I am trying to write unicode char in to text file using the following python code
with codecs.open("File.txt", mode='wb', encoding='utf-8') as f:
f.write(str(u'\u6587\u5b66\u5b66\u58eb 2005\u5e743\u6708\uff1a \u83b7\u5927\u5b66\u82f1\u8bed\u516d\u7ea7\u8bc1\u4e66'))
f.write('\n')
f.close()
I am getting the following error
'ascii' codec can't encode characters in position 0-3: ordinal not in range(128)
Please help me in resolving this issue