OA. free
Free
Sigmoid Core Computer Science Core Computer Science Medium

Question 7 Stack is a distinct type of list where the operations are performed at one end...

Sigmoid technical mcq question, verified with a worked answer. Free to practise - no sign-up.

Stack is a distinct type of list where the operations are performed at one end of the stack.

Determine:

  1. What is the principle under which stack operations take place?
  2. Which method cannot be performed in stack?

Select an option

Choose one option.
Show answer & explanation
Answer: C. C) 1) Last in first out

Stacks operate under the LIFO (Last In First Out) principle, and standard stack primitives (push, pop, top) do not support arbitrary in-place element replacement.

Step-by-step Derivation:
Step 1: Stacks follow LIFO.
Step 2: Arbitrary element replacement is not a standard stack operation.