P16675 [CodeChef] REMIX
普及
题目描述

Chef Loves to listen to remix songs, but currently he had already finished the entire playlist of remix songs.
As Chef is smart, so he thought let's make my own remix songs of the original songs.
Chef is not having much knowledge of making remix songs, so he came up with the simple technique in which he will pick the word which contains the smallest number of characters from the lyrics of the song, and then he will append that word to the start and end of the lyrics, also Chef will insert this word between every two words of the lyrics.
Note: While inserting a new word Chef will also insert extra white-spaces, so that every word in the final remixed lyrics is separated by space.
It is Recommended to use fast Input/Ouput techniques.

-----Input:-----
- The input contains the text $S$, which denotes the lyrics of the song.

-----Output:-----
- Print the Remixed, lyrics as done by Chef.

-----Constraints:-----
- $1 \leq$S$\leq 10^7$

-----Sample Input:-----
Mai Hu Jiyaan

-----Sample Output:-----
Hu Mai Hu Hu Hu Jiyaan Hu

输入格式

见题面

输出格式

见题面

样例输入
['Mai Hu Jiyaan']
样例输出
['Hu Mai Hu Hu Hu Jiyaan Hu']