Practice on Toph

Participate in exhilarating programming contests, solve unique algorithm and data structure challenges and be a part of an awesome community.

A Problem for String Lovers

Limits 1s, 512 MB

Razin loves strings so much that his parents decided to buy him n strings for his birthday. But in the night, his young sister accidentally reversed all the strings. Now please help him to restore the original string.

Input

First line contains an integer, n.

Then each n lines contains a string.

1 ≤ n, size of a string ≤ 100

Output

print n lines. Each line should contain the actual string of Razin.

Sample

InputOutput
2
i am boss
madam

ssob ma i
madam

Discussion

Statistics


91% Solution Ratio

HillolTalukdarEarliest, Feb '19

HillolTalukdarFastest, 0.0s

Mili290Lightest, 0 B

bokaifShortest, 43B

Submit

Login to submit

Toph uses cookies. By continuing you agree to our Cookie Policy.