题目:统计两行小写字母构成的字符串中相同的字母,并按字典序输出。
注: 先排序然后比较输出。(防止测资存在空格或是大写字母)
Description
Given two strings of lowercase letters, a and b, print the longest string x of lowercase letters such that there is a permutation of x that is a subsequence of a and there is a permutation of x that is a subsequence of b.
Input
Input file contains several lines of input. Consecutive two lines make a set of input. That means in the input file line 1 and 2 is a set of inp