Stacks Flashcards
1
Q
what’s the order principle of stack
A
last in first out
2
Q
how to implement stack using arrays
A
use size as the indicator of the top item in the stack
3
Q
how to implement stack using linkedlists
A
only allows adding to the back to conform to LIFO