public interface StackInterface
Modifier and Type | Method and Description |
---|---|
boolean |
isEmpty()
Check whether the stack is empty
|
int |
pop()
Removes the value at the top of this stack and returns that value as the value of this function.
|
void |
push(int value)
Pushes a value onto the top of this stack.
|
void |
reset()
Reset the array: all elements are removed (set to 0)
|
int |
size()
Returns the numbers of elements in the stack.
|
int |
top()
Returns the value at the top of this stack (with deletion).
|
void push(int value)
int pop()
int top()
int size()
void reset()
boolean isEmpty()