Use a stack: ten plus five gives fifteen; sixty divided by six gives ten. Multiply the two results to obtain one hundred fifty, then subtract eight, giving one hundred forty-two. Thus C.
More Stacks and Queues questions
GATE 2026 CS (CS2) Q50– Consider a stack S and a queue Q, both initially empty and each capable of storing ten…
GATE 2025 CS (CS2) Q45– Consider a stack data structure into which we can PUSH and POP records. Assume that each…
GATE 2024 CS (CS2) Q48– Let S1 and S2 be two stacks. S1 has capacity 4 and already holds 100, 200, 300, 400 (400…
GATE 2023 CS Q59– Consider a sequence a of elements a 0 = 1, a 1 = 5, a 2 = 7, a 3 = 8, a 4 = 9, and a 5 =…
GATE 2022 CS Q62– Consider the queues Q 1 containing four elements (1, 2, 3, 4 with 1 at the head) and Q 2…
GATE 2021 CS (CS1) Q31– Consider the following sequence of operations on an empty stack. push(54); push(52);…