# Aricent Stacks, Queues Quiz-1

Question 1

Time: 00:00:00
Each step in the evaluation of an Infix expression refers to the encounter of a token. In the evaluation of the fully parenthesized Infix expression -
((1*2)+4-((7*6)/(8-9)))
Which of the following options shows the contents of the Stack after 7th step

((*)+-(

((*)+-(

((1*2)+

((1*2)+

((2+

((2+

(2+4

(2+4

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 2

Time: 00:00:00
Consider the given conditions in regards to the circular queue
1) (FRONT = 0) and (REAR =CAPACITY - 1)
2) FRONT = REAR
3)FRONT = CAPACITY-- REAR
Which of the above conditions tests the overflow condition of a circular queue?

Only l

Only l

Only2

Only2

Only 3

Only 3

Both l and 2

Both l and 2

Both l and 3

Both l and 3

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 3

Time: 00:00:00
Group A
A. Indirect Addressing
B. Immediate Addressing
C. Indexed Addressing
D. Autodecrement Addressing

Group B
1. Constant
2. Arrays
3. Loops
4. Pointers

1) A-4.B-3, C-2, D-1

1) A-4.B-3, C-2, D-1

A-3.B-2, C-4, D-1

A-3.B-2, C-4, D-1

A-2,B-1,C-4,D-3

A-2,B-1,C-4,D-3

A-4,B-1,C-2,D-3

A-4,B-1,C-2,D-3

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 4

Time: 00:00:00
Choose the correct answer
Stack is useful for implementing

Radix search

Radix search

Breadth first search

Breadth first search

Recursion

Recursion

None of these

None of these

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 5

Time: 00:00:00
Choose the correct answer
Which of the following data structure may give overflow error, even though the current number of element in it is less than its size?

Queue implemented in a linear array

Queue implemented in a linear array

Queue implemented in a circularly connected array

Queue implemented in a circularly connected array

Stack implemented in a linear array

Stack implemented in a linear array

none of these

none of these

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 6

Time: 00:00:00
Choose the correct answer
A is an empty stack. The following operations are done on it.
PUSH(1)
PUSH(2)
POP
PUSH(5)
PUSH(6)
POP
What will the stack contain after these operations. (Top of the stack is underlined)

_5_ 6

_5_ 6

1 _5_

1 _5_

_5_ 6

_5_ 6

_1_ 5

_1_ 5

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 7

Time: 00:00:00
A stack is implemented as a linear array A[0…N-1]. Noor writes the following functions for popping
an element from the stack.
function POP( top, N )
{
if(X)
{
top = top - 1
}
else
{
print "Underflow"
}
return top
}
Fill in the condition X

top< N-1

top< N-1

top

top

top>1

top>1

top >= 0

top >= 0

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 8

Time: 00:00:00
How many stack/s need for implementing a queue?

2

2

3

3

1

1

5

5

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 9

Time: 00:00:00
Choose the correct answer
A queue is implemented by a linear array of size 10 (and not as a circularly connected array). Front and Rear are represented as an index in the array. To add an element, the rear index is incremented and the element is added. To delete an element, the front index is incremented. The following operations are done on an empty queue.
ADD 1; DELETE; ADD 2; ADD 3; ADD 4; DELETE, DELETE
After this set of operations, what is the maximum capacity of the queue?

6

6

7

7

10

10

None

None

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

Question 10

Time: 00:00:00
how many arrays are required to implement a priority queue?

1

1

2

2

3

3

4

4

Once you attempt the question then PrepInsta explanation will be displayed.

Please login to submit your explanation

Start

["0","40","60","80","100"]
["Need more practice! \r\n \r\n","Keep trying! \r\n \r\n","Not bad! \r\n \r\n","Good work! \r\n \r\n","Perfect! \r\n \r\n"]

Personalized Analytics only Availble for Logged in users

Analytics below shows your performance in various Mocks on PrepInsta

Your average Analytics for this Quiz

Rank

-

Percentile

0%

Get over 200+ Courses under One Subscription

Don’t settle Learn from the Best with PrepInsta Prime Subscription

Learn from Top 1%

## One Subscription, For Everything

The new cool way of learning and upskilling -

Limitless Learning

One Subscription access everything

Job Assurance

Get Access to PrepInsta Placement Cell

Top Faculty

from FAANG/IITs/TOP MNC's

## Get over 200+ course One Subscription

Courses like AI/ML, Cloud Computing, Ethical Hacking, C, C++, Java, Python, DSA (All Languages), Competitive Coding (All Languages), TCS, Infosys, Wipro, Amazon, DBMS, SQL and others.