12188: 最长&最短文本

Memory Limit:32 MB Time Limit:1.000 S
Judge Style:Text Compare Creator:
Submit:3 Solved:0

Description

输入多行字符串,请按照原文本中的顺序输出其中最短和最长的字符串,如果最短和最长的字符串不止一个,请全部输出。

Input

输入包括多行字符串,字符串的长度len,(1<=len<=1000)。

Output

按照原文本中的顺序输出其中最短和最长的字符串,如果最短和最长的字符串不止一个,请全部输出。

Sample Input Copy

hello
she
sorry
he

Sample Output Copy

he
hello
sorry