As a studious French officer, Pierre-François Bouchard is interested in ancient languages. In a recent expedition, he uncovered a clay tablet with what appeared to be inscriptions in a long-forgotten language. Having made a copy of all the words on the tablet, Pierre-François would like to create a dictionary for future scholars. He's transcribed ~N~ words from the tablet, and has contacted you in the hopes that you'll be able to sort them for him.
Each word is formed only from lowercase Latin characters no longer than ~20~ characters in length. You are to organize the words into alphabetical sections by first letter, with individual sections sorted in lexicographically increasing order.
A string ~S~ is said to be lexicographically smaller than a string ~T~ if ~|S| < |T|~ and ~S~ is a prefix of ~T~ or ~S_k < T_k~ and ~S_i = T_i~ ~(0 \le i < k, 0 \le k < \min(|S|, |T|))~. Here, ~|X|~ denotes the length of the string.
The first line of input will contain the number ~N~ ~(1 \le N \le 10)~.
The following ~N~ lines contain each a word.
For each non-empty section, output a line containing all words in lexicographical order separated by
, (a comma and space).
5 eggnog cake biscuits chocolate tea
biscuits cake, chocolate eggnog tea