 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
| • |
When
implementing the code for a stack's
|
|
operations,
we need to keep in mind that
|
|
|
we
should have functions to push data
|
|
|
and
to pop data.
|
|
| • |
This
way we can hide the implementation
|
|
|
details
from the user as to how these
|
|
|
routines
actually access our
|
|
|
memory...why?
|
|
|
|
– |
because
you can actually implement stacks using either
|
|
|
arrays
or using linked lists with dynamic memory
|
|
|
allocation.
|
|