RotateRight
✖
RotateRight
Details

- RotateRight[expr,-n] rotates n positions to the left.
- RotateRight can be used on SparseArray and Association objects.
Examples
open allclose allBasic Examples (4)Summary of the most common use cases
Rotate two positions to the right:
In[1]:=1

✖
https://wolfram.com/xid/0rs500v92-ckf
Out[1]=1

Rotate one position to the right:
In[1]:=1

✖
https://wolfram.com/xid/0rs500v92-e1r
Out[1]=1

Rotate Association one position to the right:
In[1]:=1

✖
https://wolfram.com/xid/0rs500v92-k0c2xp
Out[1]=1

Rotate Association on the first and second levels:
In[1]:=1

✖
https://wolfram.com/xid/0rs500v92-bj8rfn
Out[1]=1

Generalizations & Extensions (2)Generalized and extended use cases
Applications (4)Sample problems that can be solved with this function
Successively rotate a list right:
In[1]:=1

✖
https://wolfram.com/xid/0rs500v92-njf
Out[1]=1

Rotate successive rows of a matrix by their row number:
In[1]:=1

✖
https://wolfram.com/xid/0rs500v92-qwi

In[1]:=1

✖
https://wolfram.com/xid/0rs500v92-oqf
Out[1]=1

In[1]:=1

✖
https://wolfram.com/xid/0rs500v92-p8y
Out[1]=1

Wolfram Research (1988), RotateRight, Wolfram Language function, https://reference.wolfram.com/language/ref/RotateRight.html (updated 2003).
✖
Wolfram Research (1988), RotateRight, Wolfram Language function, https://reference.wolfram.com/language/ref/RotateRight.html (updated 2003).
Text
Wolfram Research (1988), RotateRight, Wolfram Language function, https://reference.wolfram.com/language/ref/RotateRight.html (updated 2003).
✖
Wolfram Research (1988), RotateRight, Wolfram Language function, https://reference.wolfram.com/language/ref/RotateRight.html (updated 2003).
CMS
Wolfram Language. 1988. "RotateRight." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2003. https://reference.wolfram.com/language/ref/RotateRight.html.
✖
Wolfram Language. 1988. "RotateRight." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2003. https://reference.wolfram.com/language/ref/RotateRight.html.
APA
Wolfram Language. (1988). RotateRight. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/RotateRight.html
✖
Wolfram Language. (1988). RotateRight. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/RotateRight.html
BibTeX
✖
@misc{reference.wolfram_2025_rotateright, author="Wolfram Research", title="{RotateRight}", year="2003", howpublished="\url{https://reference.wolfram.com/language/ref/RotateRight.html}", note=[Accessed: 29-March-2025
]}
BibLaTeX
✖
@online{reference.wolfram_2025_rotateright, organization={Wolfram Research}, title={RotateRight}, year={2003}, url={https://reference.wolfram.com/language/ref/RotateRight.html}, note=[Accessed: 29-March-2025
]}