file = open('test.txt', 'r')result = list()for c in file.readlines():c_array = c.split(" ")result.append(c_array[-1])print(result)
空格分割后按元素获取