NVIDIA interview question

rotate array by k in place