The first Issue... closed :)

2017-08-17  本文已影响0人  Gouwal

Thanks all

"\ufeff" 报错问题查询链接与解决方案

"This problem arise basically when you save your python code in a UTF-8 or UTF-16 encoding because python add some special character at the beginning of the code automatically (which is not shown by the text editors) to identify the encoding format. But, when you try to execute the code it gives you the syntax error in line 1 i.e, start of code because python compiler understands ASCII encoding. when you view the code of file using read() function you can see at the begin of the returned code '\ufeff' is shown. *** The one simplest solution to this problem is just by changing the encoding back to ASCII encoding(for this you can copy your code to a notepad and save it Remember! choose the ASCII encoding...*** Hope this will help."


The first Issue... closed :)
上一篇 下一篇

猜你喜欢

热点阅读