Syntax Error: Non-UTF-8 code start with \xce’in file

Question:

SyntaxError: Non-UTF-8 code starting with '\xce' in file E:/python_work/study/no_black.py on line 6, but no encoding declared; see http://python.org/dev/peps/pep-0263/ for details

solve:

Write [# – * – Coding: GBK – * -] on the first line of the PY file (including #, #, and one space after #)

# -*- coding: gbk -*- 


Read More: