A40332. 数据文件“abc.txt” 中包含若干个英文单词, 如图所示:读取文件“abc.txt” 中数据的 Python 程序段如下:file = 'abc.txt'word_b = []for word in open(file): if word[0:1] = = 'a' and len(word)>4: word_b.append(word)该程序段执行后, 列表 word_b 中的数据为? ( )
单选题
困难
知识点
题目描述
数据文件“abc.txt” 中包含若干个英文单词, 如图所示:
读取文件“abc.txt” 中数据的 Python 程序段如下:
file = 'abc.txt'
word_b = []
for word in open(file):
if word[0:1] = = 'a' and len(word)>4:
word_b.append(word)
该程序段执行后, 列表 word_b 中的数据为? ( )
选项(单选)
答案解析
详细答案解析为会员权益,按每日次数查看。
开通 / 升级会员
上一题
下一题