Stack LotusScript class

A useful class for you to use at your own risk. An implementation of a last-in-first-out data structure. Can be used like:


Dim stack As New Stack()
Call stack.push("Domino")
Call stack.push("Notes")
Call stack.push("R7")

Print "Stack is: " & stack.toString()

Print "First: " & stack.pop()
Print "Second: " & stack.pop()
Print "Third: " & stack.pop()
' This will produce the output:
' R7
' Notes
' Domino


Thanks to Vitezsla Vit VLCEK and Chad ”Smiley” Schelfhout for pointing out bugs in the original class.