Skip to content

Instruction 4000 CONCAT

HoverCatz edited this page Mar 8, 2024 · 1 revision

This will CONCAT (aka concentrate or add) the last 2 elements (the top/the right-most/the last added element) on the stack together.
It first pops the two elements, then adds them together as strings, and puts the resulting string back onto the stack.


Pseudo: string(A) + string(B) = string(AB)

Stack before: ${[\space\color{#947cdd}'Hello'\space\color{white}, \space\color{#947cdd}'\space world'\color{white}\space]}$

CONCAT

Stack after: ${[\space\color{#947cdd}'Hello\space world'\space\color{white}]}$

Clone this wiki locally