
- 帖子
- 35
- 积分
- 80
- 技术
- 8
- 捐助
- 0
- 注册时间
- 2020-5-27
|
z = input("please input row number:")
dataList=[]
with open("b.txt", 'r', encoding='UTF-8') as f: # open your file
readList = f.read().splitlines()
for data in readList:
if data.startswith(z):
rowData=["",""]
dataList.append(rowData)
rowData[0]=data.split()[-2].strip()
rowData[1]=data.split()[-1].strip()
for r in dataList:
print(r) |
-
2
评分人数
-
|