built in compound operators: rotate-left


rotate-left:
    description:
        rotate-left input-seq
        rotate each superposition in input-seq left by 1 step

        rotate-left[n] input-seq
        rotate each superposition in input-seq left by n steps, modulus by the size of the corresponding superposition

    examples:
        rotate-left (|one> + |two> + |three> + |four> + |five> + |six> + |seven>)
            |two> + |three> + |four> + |five> + |six> + |seven> + |one>

        rotate-left[3] (|one> + |two> + |three> + |four> + |five> + |six> + |seven>)
            |four> + |five> + |six> + |seven> + |one> + |two> + |three>

    see also:
        rotate-right, srotate-right, srotate-left
Home