Added function to right shift array.