+ 3
In what way does our stack ADT implementations support: a. Encapsulation? b. Information hiding?
In what way does our stack ADT implementations support: a. Encapsulation? b. Information hiding?
1 Answer
+ 2
a) you can only access the stacks top element throw a function.
(the stack sort of does it's own thing and you just ask it to do sth)
b) when you encapsulate the information is hidden, and can only be accessed throw functions, limiting the access