Takes an array of integers and returns that array rotated by N positions