# Common Suffix

Mr. Wang is a freshman majoring in computer science. The teahcer asks him to find the

longest common suffix string amongst an array of strings. Can you help him to solve it?

## Input

The input consists of multiple tests. For each test:

Line 1: A number n indicates the number of strings. (\(1 \leq N \leq 1000\))

Line 2: n character strings separated by space.(each string: \(1 \leq length \leq 10000\))

Tests end when n=0.

## Output

For each case, print out the longest common suffix string. If not exists, print out None.

## Sample Input

2
welcome scuhome
5
software computer helloer worlder finder
1
lastone
0

## Sample Output

ome
None
lastone

## Author

imcmy