Advertisement

程序设计实训作业---单词索引编排

阅读量:
  1. 【问题描述】

在现有文件in.txt中存储了一篇英文文章(内容待处理)。我们需要将其中的关键词汇提取出来,并输出至out.txt文件中。假设如下:1. 文章可能未经过格式修饰或排版处理,在内容完整性上也可能存在缺失;2. 文章中的不同单词数量最多为1000个,并且每个单词的长度均不超过50个字母。

【输入形式】

保存英文文章的文件in.txt位于当前目录下。

【输出形式】

为了生成按照从小到大的字典顺序排列输出的词汇表,请确保它们被放置在当前目录中的out.txt文件中,并且每个单词独立成行。

【样例输入1】

假设文件in.txt内容为:

There are two notable versions of the ANSI international standards for the C programming language. The initial release of the ANSI/ANSI C standards committee approved the first version in 1989. This standard is commonly referred to as ANSI/ISO C or simply C89. The later edition of the C standard was finalized in

全部评论 (0)

还没有任何评论哟~