answersLogoWhite

0

in dynamic stack we don't have to initialize the size of array while in static stack we have 2 initialize it ......

User Avatar

Wiki User

9y ago

What else can I help you with?

Continue Learning about Engineering

When will stack overflow and stack underflow condition occur insequential organization?

In a sequential organization, a stack overflow condition occurs when there is an attempt to push an element onto a stack that is already full, exceeding its allocated memory limit. Conversely, a stack underflow condition occurs when there is an attempt to pop an element from an empty stack, which has no elements to remove. Both conditions can lead to runtime errors and need to be handled to maintain the integrity of the stack operations. Proper checks should be implemented to prevent these situations.


What is the empty condition of stack?

The empty condition of a stack occurs when there are no elements present in the stack. This is typically checked using a method that verifies if the stack's size is zero or if a pointer/reference to the top element is null or None. An empty stack cannot support operations like pop or peek, as there are no elements to remove or access. In programming, attempting to perform these operations on an empty stack usually results in an error or exception.


Representation of stack data structure in c plus plus?

Stack is an abstract data type that allows you to input and output data in a way that the first data which was placed in the stack will be the last one to get out. We use physical examples of stack in our daily lives such as the stack of dishes or stack of coins where you only add or remove objects from the top of the stack. You can see the implementation in c++ in related links, below.


Difference between dynamic and static memory allocation?

Static memory allocation is memory allocated on the "stack" and cannot be resized after the initial allocation, while dynamic memory allocation is memory allocated in the "heap", and can be dynamically expanded and shrunk as necessary.


What is hardware stack and software stack?

hardware stack - a stack implemented in and entirely managed by hardware, this stack will have dedicated memory and registers in the physical hardware of the system.software stack - a stack implemented with and entirely managed by software, this stack will use a small piece of main RAM and variables declared in the program software (making it much easier to modify if necessary than a hardware stack).

Related Questions

Stack can be described as a pointer Explain?

Stack is also dynamic memory, without the hassle. Dynamic memory uses pointers to check its value, free the memory, etc.


What is stackunderflow?

An error condition that occurs when an item is called for from the stack, but the stack is empty.


When will stack overflow and stack underflow condition occur insequential organization?

In a sequential organization, a stack overflow condition occurs when there is an attempt to push an element onto a stack that is already full, exceeding its allocated memory limit. Conversely, a stack underflow condition occurs when there is an attempt to pop an element from an empty stack, which has no elements to remove. Both conditions can lead to runtime errors and need to be handled to maintain the integrity of the stack operations. Proper checks should be implemented to prevent these situations.


What is the empty condition of stack?

The empty condition of a stack occurs when there are no elements present in the stack. This is typically checked using a method that verifies if the stack's size is zero or if a pointer/reference to the top element is null or None. An empty stack cannot support operations like pop or peek, as there are no elements to remove or access. In programming, attempting to perform these operations on an empty stack usually results in an error or exception.


When one variable increase while the other variable deacreases is a statement indicating an inverse relationship?

No. That condition is necessary but not sufficient.No. That condition is necessary but not sufficient.No. That condition is necessary but not sufficient.No. That condition is necessary but not sufficient.


Why dynamic stacks need not to check overflows?

Dynamic stacks do not need to check for overflow, per se, because they will automatically allocate extra storage if it is needed. However, it is still necessary to check for the out-of-memory condition, so the truth is that dynamic stacks do need to check for overflow, so to speak, because out-of-memory is similar in consequences to overflow.


Representation of stack data structure in c plus plus?

Stack is an abstract data type that allows you to input and output data in a way that the first data which was placed in the stack will be the last one to get out. We use physical examples of stack in our daily lives such as the stack of dishes or stack of coins where you only add or remove objects from the top of the stack. You can see the implementation in c++ in related links, below.


Difference between dynamic and static memory allocation?

Static memory allocation is memory allocated on the "stack" and cannot be resized after the initial allocation, while dynamic memory allocation is memory allocated in the "heap", and can be dynamically expanded and shrunk as necessary.


What is hardware stack and software stack?

hardware stack - a stack implemented in and entirely managed by hardware, this stack will have dedicated memory and registers in the physical hardware of the system.software stack - a stack implemented with and entirely managed by software, this stack will use a small piece of main RAM and variables declared in the program software (making it much easier to modify if necessary than a hardware stack).


Joint operational planning pertains to what type of dynamic condition?

flexible and responsive


What is local data?

Local data is automatic data associated with the block that is presently in scope. It is dynamic, usually allocated from the stack, and it goes away when you leave the block.


Where linked list using?

linked list are used for creation of stack,queues to use memory in optimum manner linked list are used as they are dynamic in nature