• + 1 comment

    Good job, but int startIndex = (a.length - k)%a.length; can be simplified by int startIndex = a.length - k;.