I'm trying to write a CSV with non-ascii character using Python 3.
import csv
with open('sample.csv', 'w', newline='', encoding='utf-8') as csvfile:
spamwriter = csv.writer(csvfile, delimiter=' ',
quotechar='|', quoting=csv.QUOTE_MINIMAL)
spamwriter.writerow("嗨")
When I open the Excel file, see å—¨
instead. Am I doing something wrong here?