#Read a *.txt file using the read_table() function in the Pandas library
data = pd.read_table(r'D:\New\test.txt',delimiter=',',encoding = 'UTF-8')
print(data)
Title defect Solution: add “R” before the path to solve it.
python D:\New\MyTest.py
name date id
0 jianghu 20210201 00001
1 jianghu1 20210202 00002
2 jianghu2 20210203 00003