Stack in Data Structure

@T-Bone

This question paper focuses on the "Stack" of Data Structure. These Multiple Choice Questions (mcq) should be practiced to improve the Data Structure skills required for various interviews (campus interview, walk-in interview, company interview), placement, entrance exam and other competitive examinations.

This question paper focuses on the "Stack" of Data Structure. These Multiple Choice Questions (mcq) should be practiced to improve the Data Structure skills required for various interviews (campus interview, walk-in interview, company interview), placement, entrance exam and other competitive examinations.

Questions

1. Which one of the following is an application of Stack Data Structure?

Mark the correct option

2. Process of inserting an element in stack is called ____________.

Mark the correct option

3. The postfix form of A*B+C/D is?

Mark the correct option

4. hich of the following is true about linked list implementation of stack?

Mark the correct option

5. n a stack, if a user tries to remove an element from empty stack it is called _________.

Mark the correct option

6. Consider the following pseudocode that uses a stack. What is output for input "letsfindc"? declare a stack of characters while ( there are more characters in the word to read ) { read a character push the character on the stack } while ( the stack is not empty ) { pop a character off the stack write the character to the screen }

Mark the correct option

7. ntries in a stack are "ordered". What is the meaning of this statement?

Mark the correct option

8. The prefix form of A-B/ (C * D ⋀ E) is?

Mark the correct option

9. ollowing is an incorrect pseudocode for the algorithm which is supposed to determine whether a sequence of parentheses is balanced: Which of these unbalanced sequences does the above code think is balanced? declare a character stack while ( more input is available) { read a character if ( the character is a '(' ) push it on the stack else if ( the character is a ')' and the stack is not empty ) pop a character off the stack else print "unbalanced" and exit } print "balanced"

Mark the correct option

10. What is the value of the postfix expression 6 3 2 4 + – *:

Mark the correct option

11. Process of removing an element from stack is called __________

Mark the correct option

12. Pushing an element into stack already having five elements and stack size of 5 , then stack becomes

Mark the correct option

13. Which of the following applications may use a stack?

Mark the correct option

14. Consider the usual algorithm for determining whether a sequence of parentheses is balanced. The maximum number of parentheses that appear on the stack AT ANY ONE TIME when the algorithm analyzes: (()(())(())) are:

Mark the correct option

15. Consider the usual algorithm for determining whether a sequence of parentheses is balanced. Suppose that you run the algorithm on a sequence that contains 2 left parentheses and 3 right parentheses (in some order). The maximum number of parentheses that appear on the stack AT ANY ONE TIME during the computation?

Mark the correct option

16. The data structure required to check whether an expression contains balanced parenthesis is?

Mark the correct option

17. Here is an infix expression: 4 + 3*(6*3-12). Suppose that we are using the usual stack algorithm to convert the expression from infix to postfix notation. The maximum number of symbols that will appear on the stack AT ONE TIME during the conversion of this expression?

Mark the correct option

18. What data structure would you mostly likely see in a non recursive implementation of a recursive algorithm?

Mark the correct option

19. The process of accessing data stored in a serial access memory is similar to manipulating data on a ________

Mark the correct option

20. The postfix form of A*B+C/D is?

Mark the correct option

21. Which data structure is needed to convert infix notation to postfix notation?

Mark the correct option

22. The prefix form of A-B/ (C * D ^ E) is?

Mark the correct option

23. The postfix form of A*B+C/D is?

Mark the correct option

24. What is the result of the following operation Top (Push (S, X))

Mark the correct option

25. The prefix form of an infix expression p + q – r * t is?

Mark the correct option

Index of Questions