Well formed parenthesis can be checked using following data structure ?
Stack
List
Queue
Hash Map
SHOW ANSWERPost fix form of
A + (B * C)
is -
AB * C +
ABC * +
AB + C *
ABC + *
SHOW ANSWERPost fix form of -
(A + B) * C
ABC + *
AB * C +
ABC * +
AB + C*
SHOW ANSWERWhen user switch from one function to other then the details of previous function are stored into the stack !
False
True
SHOW ANSWERConsider following Scenario -
The five items : P,Q,R,S and T are inserted into stack A one after other starting from T in reverse order
The stack is popped three times and each element is inserted into another stack B.
Then two elements are deleted from the stack B and pushed back onto the stack A.
What are the topmost elements of stack A and Stack B respectively?
R Q
Q P
Q R
R P
SHOW ANSWERIf memory for the run-time stack is only 150 cells(words), how big can N be in Factorial(N) before stack overflow?
66
60
26
12
SHOW ANSWERA postfix expression is just the reverse of the prefix expression !
False
True
SHOW ANSWERStack A has 3 Elements in it Say X,Y and Z with X on top.
Stack B is empty.
An Element popped out from Stack A can be printed immediately or pushed to stack B.
An Element popped out from Stack B can only be printed.
In this arrangement, which of the following permutations of X,Y,Z are not possible ?
Z Y X
Y Z X
Y X Z
Z X Y
SHOW ANSWERAn item that is read as input can be either pushed to a stack and later popped and printed, or printed directly. Which of the following will be the output if the input is the sequence of items 1, 2, 3, 4, 5?
3 4 5 1 2
5 4 3 1 2
3 4 5 2 1
1 5 2 3 4
SHOW ANSWERA linear list of elements in which deletion can be done from one end (front) and insertion can take place only at the other end (rear) is known as a ?
Queue
Stack
Tree
Linked list
SHOW ANSWERThe data structure required for Breadth First Traversal on a graph is?
Stack
Array
Queue
Tree
SHOW ANSWERLet the following circular queue can accommodate maximum six elements with the following data
front = 2 rear = 4
queue = _______; L, M, N, ___, ___
What will happen after ADD O operation takes place?
front = 2 rear = 5
queue = ______; L, M, N, O, ___
front = 3 rear = 5
queue = L, M, N, O, ___
front = 3 rear = 4
queue = ______; L, M, N, O, ___
front = 2 rear = 4
queue = L, M, N, O, ___
SHOW ANSWERA queue is a ?
FIFO (First In First Out) list
LIFO (Last In First Out) list.
Ordered array
Linear tree
SHOW ANSWER