with open("/Users/caizuguang/Desktop/作业一素材.txt", "r") as f: # 打开文件
data = f.read() # 读取文件
suffix = '顺丰控股股份有限公司'
index = data.find(suffix)
data = data[0:index]
data = data.replace('\n','')
data = data.split('.')
data = data[-2].split(' ')
print('最后一个句子的长度是:%s' % len(data))