AKVQLD01 - Cartman Reverses Strings 200 pts

no tags 

In the recent poll at South Park elementary school, Cartman was voted as the ugliest kid in the school. Angry Cartman wants to take the revenge, but instead he told everyone "Screw you guys, I'm going home". But he came back to the school at night and opened the school's primary database file and reversed all the strings in it to take his revenge, and you are the one who wrote the program for it.

Input

First Line Contains "T", the number of test cases. Each of next "T" lines contain a string consisting of only lowercase English letters.

Output

For each test case, print reverse of the given string.

Constraints

1 <= T <= 1000

1 <= Length of string <= 1000

Example

Input:
3
a
cartman
stan

Output:
a
namtrac
nats


Added by:Ankit Kumar Vats
Date:2013-07-22
Time limit:1s
Source limit:50000B
Memory limit:1536MB
Cluster: Cube (Intel G860)
Languages:All except: ASM64
Resource:Self