answersLogoWhite

0

1. Expression evaluation and syntax parsing

Calculators employing reverse Polish Notation use a stack structure to hold values. Expressions can be represented in prefix, post fix or infix notations. Conversion from one form of the expression to another form may be accomplished using a stack. Many compilers use a stack for parsing the syntax of expressions, program blocks etc. before translating into low level code. Most of the programming languages are context-free languages allowing them to be parsed with stack based machines.

2. Runtime memory management

A number of programming languages are stack oriented , meaning they define most basic operations (adding two numbers, printing a character) as taking their arguments from the stack, and placing any return values back on the stack. For example, Post Script has a return stack and an operand stack, and also has a graphics state stack and a dictionary stack.

3. Security

Some computing environments use stacks in ways that may make them vulnerable to security breaches and attacks. Programmers working in such environments must take special care to avoid the pitfalls of these implementations.

User Avatar

Wiki User

15y ago

What else can I help you with?

Related Questions

Can stack be called fifo data structure?

No. A stack is a LIFO (Last In First Out) data structure.A queue is a FIFO (First In First Out) data structure.


Explain The merits of using a deque to implement a stack in data structure?

Explain The merits of using a deque to implement a stack in data structure


What is the resource requirement of stack in a data structure?

no answer


What is a stack in data structure?

A stack in Data structure is a LIFO structure. Last In First Out. Think of it as a stack of books or a stack of trays in a cafeteria line. when you are in a line in a cafeteria you take the tray that is on the top and the worker place new washed ones also on the top. So deletion and insertion all done at one end, it is called the top of the stack. In Computer Programming Stacks are so important and have too many applications such as the evaluation of Mathematical expressions. Also note that a stack is unlike a queue structure. Queue data structure is FIFO. First In First Out as in a bank teller line.


Which type of data structure is used in ATM to take the printout of last 5 transactions?

stack data structure.


What are some common operations that can be performed on a stack data structure?

Common operations that can be performed on a stack data structure include push (adding an element to the top of the stack), pop (removing the top element from the stack), peek (viewing the top element without removing it), and isEmpty (checking if the stack is empty).


How can you add different type of data in a stack?

stack is a linear data structure in which data item is either inserted or deleted at one end there are mainly two operations performed on stack.they're push poppush:writing a value to the stack is push or moving the stack pointer up to accomodatethe new item. pop:reading a value from stack or moving the stack pointer down.


The best data structure to check whether an arithmetic expression has balanced parentheses is a?

stack


Which data structure is needed to convert infix notations to post fix notations?

stack is the basic data structure needed to convert infix notation to postfix


How can I efficiently use a stack to sort elements in a data structure?

To efficiently use a stack to sort elements in a data structure, you can follow these steps: Push all elements into the stack. Create a temporary stack to store the sorted elements. While the original stack is not empty, pop an element from the original stack. Compare the popped element with the top element of the temporary stack. If the popped element is greater, push it onto the temporary stack. If the popped element is smaller, keep popping elements from the temporary stack and pushing them back onto the original stack until the temporary stack is empty or the top element is greater. Repeat steps 3-6 until the original stack is empty. The elements in the temporary stack will now be sorted in ascending order. By following these steps, you can efficiently use a stack to sort elements in a data structure.


What is stacks in data structure?

Stack is a data structure which is closed at one end. last in first outhi


What is LIFO in Data Structure?

LIFO stands for Last In First Out. Ex: Stack