a=[] with open('test5','r',encoding='utf-8') as z: while True: w=z.readline() a.append(w) if z.readline()=="": break for i in range(len(a)): print(a[i][3:13])
test5中手机号是“ 14141414114 ” 提取中间的手机号