CBSE · 083Class XII · 2023Section A1 mark

Question 18

30 March 2023 · Computer Science (083)

Assertion (A) : A stack is a LIFO structure. Reason (R) : Any new element pushed into the stack always gets positioned at the index after the last existing element in the stack.

Answer

(c) (A) is true but (R) is false.

Explanation

Stacks follow LIFO (Last In, First Out). (R) is considered false because a stack is defined abstractly by its 'top'; indices are an implementation detail, not part of the definition. CBSE also accepted (a) and (b) for full marks.