Skip to content
Official PYQ · 2002

GATE CS 2002 Q1.7 — Regular and Context-free Languages

Explain with AI

The language accepted by a Pushdown Automaton in which the stack is limited to 1010 items is best described as

Choose one option
View worked solution

Answer: B

A standard Pushdown Automaton (PDA) has a finite state control and an auxiliary stack of infinite capacity. However, if the stack size is restricted to a maximum of 1010 items, the stack can only hold a finite number of configurations.

Let Γ\Gamma be the stack alphabet. The total number of possible stack configurations is given by:

N=∑i=010∣Γ∣iN = \sum_{i=0}^{10} |\Gamma|^i

Since ∣Γ∣|\Gamma| is finite, NN is also a finite constant.

We can construct an equivalent Finite Automaton (FA) where each state is a tuple (q,w)(q, w) representing:

  • q∈Qq \in Q: the current state of the PDA's finite control.
  • w∈Γ∗ with ∣w∣≤10w \in \Gamma^* \text{ with } |w| \le 10: the current contents of the stack.

Since the state space of this equivalent automaton is finite (∣Q∣×N|Q| \times N), the machine is a Finite Automaton. Therefore, the language accepted by this restricted PDA is regular.

Free practice · Your answers on this page are not saved.

Published
Report a correction
Keep exploringMore Regular and Context-free Languages questions