Skip to content
Exercises · Q1

Q.State TRUE or FALSE for the following cases:

(a) Stack is a linear data structure
(b) Stack does not follow LIFO rule
(c) PUSH operation may result into underflow condition
(d) In POSTFIX notation for expression, operators are placed after operands
Odisha ChseTextbookSubjective· 1mImportance★★★★★
23% · 3/13 Questions
✓ Free question

This is a True/False question about stack data structure and postfix notation. Each statement must be evaluated independently based on standard definitions.

This question tests your understanding of two related but distinct topics: the stack data structure and postfix (Reverse Polish) notation. Let's break down why each statement is true or false.


(a) Stack is a linear data structure

TRUE. A stack is a linear data structure because its elements are arranged in a sequential order — one after another. You can only access the topmost element, but the underlying arrangement is linear (like a list). The key property is that insertion and deletion happen at one end only (the top), but the structure itself is linear, not hierarchical (like a tree) or non-linear (like a graph).

Note

Don't confuse "linear" with "random access." A stack is linear in arrangement but provides only sequential access (LIFO).


(b) Stack does not follow LIFO rule

FALSE. This is the defining characteristic of a stack. LIFO stands for Last In, First Out — the element most recently added (pushed) is the first one to be removed (popped). Think of a stack of plates: you take the top plate (the last one placed) first. If a stack didn't follow LIFO, it wouldn't be a stack — it would be something else (like a queue, which follows FIFO).

Watch out

A common mistake is confusing LIFO with FIFO. Remember: Stack = LIFO, Queue = FIFO.


(c) PUSH operation may result into underflow condition

FALSE. Underflow occurs when you try to POP (remove) an element from an empty stack — there's nothing to remove. The PUSH operation adds an element to the stack, so it can never cause underflow. However, PUSH can cause overflow if the stack has a fixed size and is already full (in array-based implementations).

Tip

Quick memory aid:

  • PUSH → can cause overflow (stack full)
  • POP → can cause underflow (stack empty)

(d) In POSTFIX notation for expression, operators are placed after operands

TRUE. In postfix notation (also called Reverse Polish Notation or RPN), the operator follows its operands. For example, the infix expression A + B becomes A B + in postfix. Similarly, (A + B) * C becomes A B + C *. The operator is placed after both operands, hence the name "postfix."

Note

Compare with prefix notation where the operator comes before operands (e.g., + A B), and infix where it sits between them (e.g., A + B).


✓Final answer

  1. TRUE — Stack is a linear data structure.
  2. FALSE — Stack follows the LIFO rule.
  3. FALSE — PUSH can cause overflow, not underflow.
  4. TRUE — In postfix notation, operators are placed after operands.

Unlock everything free for 14 days

  • Full step-by-step solutions
  • Concept-first explanations
  • Methods, shortcuts & mistakes
  • PYQ mapping + timed mock tests

Full access for 14 days. No credit card required.