A set of words is given. Sort them according to the following rule.
We say that a string is less than a string if the reverse of is lexicographically smaller than the reverse of . In other words, a < b if reverse(a) < reverse(b), where is the string-reversal operation.
For example,
reverse("Canteen") = "neetnaC",
reverse("Home") = "emoH".
Therefore, it holds that "" < "", since "" < "".
In addition, there is a special word "ADAUniversity", which must always appear at the beginning of the sorted list, regardless of the comparison result.
The sorting must be stable, meaning that for words with identical keys, their relative order must remain unchanged.
Contains a text consisting of a set of words. Each word consists of Latin letters (uppercase or lowercase). Only spaces may appear between the words. The number of words does not exceed , and the length of each word is at most characters.
Print all the words sorted according to the described rule. Each word should be printed on a separate line.
Example 1