hex.swap (arity 3)¶
Unsafe if dst and src overlap! but safe if they are the exact same address.
hex1[:n], hex2[:n] = hex2[:n], hex1[:n]
Signature¶
def swap n, hex1, hex2 @ end { ... }
Defined in hex/memory.fj — lines 115–121 (view on GitHub).
Complexity¶
Time:
n(3@)Space:
n(3@+36)
See the complexity glossary for what @, w, dw, dbit, n mean.