def rotated

cswap-bend-cli@0.1.0.0 · swpick.bend:81

import cswap-bend-cli@0.1.0.0/swpick.bend as Swpick
import Base
import cswap-bend-cli@0.1.0.0/store/seq.bend as SSeq

81# The other slots in rotation order after `anchor`: offsets 1..n-1 of the
82# cyclic sequence. An unknown anchor counts as index 0, as in the reference.
83def rotated(+xs: List<&2, String>, +anchor: Maybe<&2, String>) -> List<&2, String>:
84  rotated2(xs, index_of(xs, SSeq.str_or(anchor, ""), 0n))

Uses (6)

Used by (1)