Smartail interview question

Code to manipulate rotated array