GATE CS 2021 · Set-1 · Arrays & Matrix Representation

NAT · 1 mark · Problem PROG-DSTR-0098

Consider the following sequence of operations on an empty stack.push(54); push(52); pop(); push(55); push(62); s=pop();Consider the following sequence of operations on an empty queue.enqueue(21); enqueue(24); dequeue(); enqueue(28); enqueue(32); q=dequeue();The value of s+q is .

Numerical answer (NAT).

Solve it on GATE DA practice →More Basic Data Structures problems

Show the worked solutionOfficial GATE Answer Key: [86.0, 86.0].See full step-by-step discussion on GateOverflow: https://gateoverflow.in/357430/gate-cse-2021-set-1-question-21

GATE DA practice: past exam problems by chapter, with worked solutions · gatedaprep.com