**Compilation/Execution Result:**

43.91%

Given an array, cyclically rotate an array by one.

**Input:**

The first line of input contains an integer T denoting the number of test cases. Then T test cases follow. Each test case contains an integer n denoting the size of the array. Then following line contains 'n' integers forming the array.

**Output:**

Output the cyclically rotated array by one.

**Constraints:**

1<=T<=1000

1<=N<=1000

1<=a[i]<=1000

**Example:
Input:**

2

5

1 2 3 4 5

8

9 8 7 6 4 2 1 3

**Output:**

5 1 2 3 4

3 9 8 7 6 4 2 1

Author: Ayush Govil 1

surbhi_7 | 219 |

Rajat Thakur 2 | 205 |

Anupam Prakash 1 | 201 |

Ibrahim Nash | 195 |

Vikram Sreenivasa | 171 |

Ibrahim Nash | 709 |

ashrepos | 574 |

shi143din | 438 |

RealHorror | 435 |

HABIB_SHEIKH | 369 |

akhayrutdinov | 4059 |

sanjay05 | 3451 |

Quandray | 2465 |

Michael Riegger | 2232 |

Jasleen Kaur 2 | 2012 |