This involves file encoding issues, different formats and drop the file has a BOM to illustrate the encoding format of this file, the BOM is invisible. For example, we write a unicode format file, and then save it as utf-8 format, this time in the program reads the file be split () split the first character will appear \ ufeff garbled!
Solution: When we read the specified file into utf-8 utf-8-sig can be. sig is the signature means, this will remove the file header BOM.
python / java using split () the first character string dividing distortion problem
Guess you like
Origin blog.csdn.net/goodgoodstudyddp/article/details/104569109
Recommended
Ranking