Error
|
|
---|---|
@Ibrahim Nash | 6379 |
@blackshadows | 6329 |
@mb1973 | 5372 |
@Quandray | 5231 |
@akhayrutdinov | 5111 |
@saiujwal13083 | 4510 |
@sanjay05 | 3762 |
@marius_valentin_dragoi | 3522 |
@sushant_a | 3459 |
@verma_ji | 3357 |
@KshamaGupta | 3318 |
Complete Leaderboard | |
|
|
@184025 | 104 |
@terabaap123 | 95 |
@anamikaprasad124 | 92 |
@arshjit_singh7 | 92 |
@kumsachin10 | 90 |
@vaibhavinayak | 75 |
@NullPointerException | 74 |
@ronaldo77 | 72 |
@TanmayJ | 70 |
@bhupindersingh25122001 | 68 |
@yanshushovasaria | 63 |
Complete Leaderboard |
Given an array A of size N, print the reverse of it.
Input:
First line contains an integer denoting the test cases 'T'. T testcases follow. Each testcase contains two lines of input. First line contains N the size of the array A. The second line contains the elements of the array.
Output:
For each testcase, in a new line, print the array in reverse order.
Constraints:
1 <= T <= 100
1 <= N <=100
0 <= Ai <= 100
Example:
Input:
1
4
1 2 3 4
Output:
4 3 2 1
We strongly recommend solving this problem on your own before viewing its editorial. Do you still want to view the editorial?
Yes