Stack¶
Import: import system.collections;
Read the usage guide for examples and common tasks. This reference lists the public declarations for this part of the library. See Reading API signatures for parameter and result notation.
Stack¶
LIFO stack backed by List<T>.
constructor¶
Creates an empty stack.
length¶
Number of elements currently stored.
push¶
Pushes value onto the top of the stack.
pop¶
Removes and returns the top element, or None when empty.
peek¶
Returns the top element without removing it, or None when empty.
clear¶
Removes every element.
iterator¶
Iterates elements from bottom to top.