by Ricardo “Rudxain” Fernández Serrata
Version 3 (April 22, 2022)
Download (15 downloads)
Rotates ANY value in 1 dimension (linear), dictionaries included.
x is the value to be rotated and d is the distance (rotation amount). If LR is falsy, rotates left. If LR is truthy, rotates right.
Also supports negative distances, but it may have bugs.
If the input is a text string with surrogate pairs, the rotation will glitch the text. To handle any Unicode string, you must use `findAll(text, "(?s).")` (equivalent to `split(text, "(?u)")`) to split it into an array of code-points, instead of code-units, then `join` at the end of processing.
Rate and review within the app in the Community section.