#C13929. Reverse Strings

    ID: 43521 Type: Default 1000ms 256MiB

Reverse Strings

Reverse Strings

You are given a list of strings. Your task is to reverse each individual string without changing the order of the strings in the list.

Input Format: The first line contains an integer n, representing the number of strings. The following n lines, each contains a single string.

Output Format: Output n lines where each line contains the reversed string corresponding to the input.

For example, if the input is:

2
hello
world

Then the output should be:

olleh
dlrow

Note: An empty string should remain empty after reversal.

The reversal of a string s can be formally described by the following formula in LaTeX:

\( s = s_1s_2\ldots s_n \) then the reversed string is \( s_n s_{n-1} \ldots s_1 \).

inputFormat

The first line contains a single integer n (number of strings).

The following n lines each contain a string that may consist of letters, digits, symbols or even be empty.

outputFormat

Output n lines, where the i-th line is the reversed version of the i-th input string.

## sample
2
hello
world
olleh

dlrow

</p>