Java Reverse a String
School Accuracy: 45.76% Submissions: 4734 Points: 0

Given a String S , print the reverse of the string as output.

INPUT: The first line consists of an integer T i.e. the number of test cases. Only line of each test case consists of an String S .

OUTPUT: Print the required output.

CONSTRAINTS:

1<=T<=100
1<=|String Length|<=103

EXAMPLES:
INPUT :

1
GeeksforGeeks

OUTPUT : 

skeeGrofskeeG

to report an issue on this page.

Editorial

We strongly recommend solving this problem on your own before viewing its editorial. Do you still want to view the editorial?

Yes

All Submissions

My Submissions:

Login to access your submissions.