|
<< Click to Display Table of Contents >> Navigation: 3. Script Language > Arrays and Data-Structures > STK. - Stack > Overview of Stack Operations |
MiniRobotLanguage (MRL)
Introduction
The STK. commands provide a robust framework for managing and manipulating stacks in MiniRobotLanguage (MRL). This overview highlights the core and advanced commands used to perform stack-related operations efficiently and effectively.
List of Stack Operations
- STK.Add: Adds the top elements of the stack and pushes the result back onto the stack.
- STK.Clear (CLR): Clears all elements in the stack while keeping the handle valid.
- STK.Duplicate (DUP): Duplicates the top element of the stack.
- STK.InvRotate: Performs an inverse rotation on the top elements of the stack.
- STK.Peek (PEK): Retrieves the top element without removing it.
- STK.Pop: Removes and retrieves the top element of the stack.
- STK.Push (PUS): Adds a new element to the top of the stack.
- STK.Reverse: Reverses the order of elements in the stack.
- STK.Rotate: Rotates the top elements of the stack.
- STK.Swap: Swaps the two topmost elements in the stack.
- STK.SwapX: Swaps elements in the stack based on specified positions or criteria.
Remarks
The STK. commands are designed to support a wide range of stack operations, enabling users to efficiently manage and manipulate data. Proper understanding of these commands is essential for effective usage in complex workflows.
See also:
• STK.Push