Prepare
Practice
Interview
Aptitude
Reasoning
English
GD
Placement papers
HR
Current affairs
Engineering
MCA
MBA
Online test
Login
Online Practice Test
>
Data Structure
« Previous
Next »
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
« Previous
Next »
Write your comments
*
*
Email must be in the form someone@domain.com
*
*
Enter the code shown above:
Please enter the code shown above
(Note: If you cannot read the numbers in the above image, reload the page to generate a new one.)
Related Content
C test (42)
C (12)
C++ for beginners (10)
C++ (20)
C++ (24)
C++ (18)
C++ (14)
C++ (12)
C++ (15)
C++ (15)
Data structure (20)
Data structure (10)
Data structure (10)
Data structure (10)
PERL (25)
VC++ (11)
Oops (30)
Mainframe (41)
Mainframe (15)
Embedded systems (15)
OOAD (49)
Advertisement
▲