← All problems‹ PrevNext ›Rotate Right by KEasy#arrays· solved by 0 · time limit 2.0 sRotate the array to the right by kkk steps: the last kkk elements move to the front.Inputnnn, then nnn integers, then kkk.OutputThe rotated array.Constraints1≤n≤1051 \le n \le 10^51≤n≤105, 0≤k≤1090 \le k \le 10^90≤k≤109Sample 1Input5 1 2 3 4 5 2 Output4 5 1 2 3