by Ricardo “Rudxain” Fernández Serrata
Version 3 (September 26, 2023)
Download (33 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.
Rudxain profile: llamalab.com/automate/community/flows/42921
Tags: cyclic permutation
LICENSE: https://unlicense.org/
5 stars | 0 | |
4 stars | 0 | |
3 stars | 1 | |
2 stars | 0 | |
1 star | 0 | |
Reports | 0 |
Rate and review within the app in the Community section.