A directory of Objective Type Questions covering all the Computer Science subjects. Here you can access and discuss Multiple choice questions and answers for various compitative exams and interviews.

Discussion Forum

Que. Suppose implementation supports an instruction REVERSE, which reverses the order of elements on the stack, in addition to the PUSH and POP instructions. Which one of the following statements is TRUE with respect to this modified stack?
a. A queue cannot be implemented using this stack
b. A queue can be implemented where ENQUEUE takes a single instruction and DEQUEUE takes a sequence of two instructions
c. A queue can be implemented where ENQUEUE takes a sequence of three instructions and DEQUEUE takes a single instruction
d. A queue can be implemented where both ENQUEUE and DEQUEUE take a single instruction each
Answer:A queue can be implemented where ENQUEUE takes a sequence of three instructions and DEQUEUE takes a single instruction
19071A05M1 :(March 30, 2020) How is this possible?
Click to Add Comment

Confused About the Answer? Ask for Details Here
Know Explanation? Add it Here

Similar Questions: