Can stack be described as a pointer?

Options
- Yes
- No


CORRECT ANSWER : Yes

Discussion Board
stack as two pointers

In practice, stack needs a head pointer to do push/pop actions. It also needs a base pointer to mark the beginning of stack frame.

For example, the base pointer is needed in stack unwinding and preventing stack underflow.

Yang 12-2-2017 12:59 AM

about explanation

Please give an example.

Sinduja. S 03-20-2017 12:02 AM

Data Structure - Stack

Yes, stack can be described as a pointer as it contains a head pointer always pointing to the topmost element of the stack. The Push and Pop operations are performed using this pointer.

Prajakta Pandit 01-31-2017 05:39 AM

M.sc computer science

A stack is represented as a pointer. The reason is that, it has a head pointer which points to the top of the stack. The stack operations are performed using the head pointer. Hence, the stack can be described as a pointer.

M.ali 01-29-2017 01:05 PM

this question is vague

do you mean "stack" as opposed to "heap" or a stack container? Neither one of these is a single pointer

steven 05-20-2016 06:54 PM

stack as pointer

yes, because it is nothing but keep the track of address so we can consider it as pointer

pravun 07-9-2014 11:29 AM

Write your comments


Enter the code shown above:

(Note: If you cannot read the numbers in the above image, reload the page to generate a new one.)


Advertisement