Open xehoth opened 7 years ago
https://blog.xehoth.cc/POJ2001-ShortestPrefixes/
Shortest Prefixes题目背景POJ 2001 题目描述给出 nnn 个单词(1≤n≤10001 \leq n \leq 10001≤n≤1000),求出每个单词的非公共前缀,如果没有,则输出自己。 输入格式输入 N 个单词,每行一个,每个单词都是由 1~20 个小写字母构成。 输出格式输出 N 行,每行由一个空格的两部分,第一部分是输入的单词,第二部分是该单词在所有单词中的非公共前缀
https://blog.xehoth.cc/POJ2001-ShortestPrefixes/
Shortest Prefixes题目背景POJ 2001 题目描述给出 nnn 个单词(1≤n≤10001 \leq n \leq 10001≤n≤1000),求出每个单词的非公共前缀,如果没有,则输出自己。 输入格式输入 N 个单词,每行一个,每个单词都是由 1~20 个小写字母构成。 输出格式输出 N 行,每行由一个空格的两部分,第一部分是输入的单词,第二部分是该单词在所有单词中的非公共前缀