girar a matriz por K vezes em trilhos

array.rotate(k)
Delightful Dormouse