100+ Stack using Queues Questions and Answers

In the Stack using Queues Questions and answers series, we have tried to cover as broad a range of topics as practically possible from basic to advanced level. All the answers given here are verified answers verified by our teachers as well as many other resources available on the internet. As far as multiple choice questions are concerned, we followed a format which would make it easier for students to find other similar questions rather than going through all answers. We do not follow any particular pattern for these type of questions, instead each question is designed keeping a particular topic in mind. These Stack using Queues Questions and Answer will help you prepare for any exam including BCA, MCA, GATE, GRE, IES, PSC, UGC NET, DOEACC Exams at all levels – you just have to practice regularly.

Stack using Queues Questions and Answers

1. To implement a stack using queue(with only enqueue and dequeue operations), how many queues will you need?

a) 1

b) 2

c) 3

d) 4

Answer: 2

2. What is the functionality of the following piece of code?
public void fun(int x)
{
                q1.offer(x);
}

a) Perform push() with push as the costlier operation

b) Perform push() with pop as the costlier operation

c) Perform pop() with push as the costlier operation

d) Perform pop() with pop as the costlier operation

Answer: Perform push() with pop as the costlier operation

3. The term Push and Pop is related to

a) Queue

b) Stack

c) Both

d) None

Answer: Stack

4. In which data structure element is inserted at one end called Rear and deleted at other end called Front.

a) Stack

b) Queue

c) Both

d) Binary Tree

Answer: Queue

More Questions on Abstract Data Types (Data Structure)

100+ Array and Array Operations MCQs and Answers
100+ Stack Operations MCQs and Answers
100+ Queue Operations MCQs and Answers
100+ Singly Linked Lists MCQs and Answers
100+ Linked Lists Operations MCQs and Answers
100+ Doubly Linked Lists MCQs and Answers
100+ Circular Linked Lists MCQs and Answers
100+ Stack using Array MCQs and Answers
100+ Stack using Linked List MCQs and Answers
100+ Queue using Array MCQs and Answers
100+ Queue using Linked List MCQs and Answers
100+ Priority Queue MCQs and Answers
100+ Double Ended Queue MCQs and Answers
100+ Queue using Stacks MCQs and Answers
100+ Stack using Queues MCQs and Answers


Categories: Abstract Data Types

%d bloggers like this: