Consider the following grammar:
where is a relational operator (e.g., <, >, ...), 0 refers to the empty statement, and are terminals.
Consider a program following the above grammar containing ten terminals. The number of control flow paths in is ________. For example, the program
has 2 control flow paths, and .
GATE CS 2017 (Forenoon) — Question 43
Theory of Computation (TOC)Context-Free Grammars & Push-Down AutomataNAT2 marksHard
A GATE question every morning
One real past-paper question every morning for your branch, answer hidden until you tap. Free on Telegram.
More on Context-Free Grammars & Push-Down Automata
- GATE CS 2026 (Forenoon) · Q25Consider the following grammar where S is the start symbol, and a and b are terminal symbols. S aSbS bS Which of the following statements i…
- GATE CS 2026 (Forenoon) · Q52Consider the following context-free grammar G : S abaaBAbba A aaBBAb bBabaa B aBb ab In the above grammar, S is the start symbol, a and b a…
- GATE CS 2026 (Afternoon) · Q29Which of the following grammars is/are ambiguous?
- GATE CS 2025 (Forenoon) · Q19Consider the following context-free grammar G , where S, A, and B are the variables (non-terminals), a and b are the terminal symbols, S is…
- GATE CS 2025 (Afternoon) · Q24Which ONE of the following languages is accepted by a deterministic pushdown automaton?
- GATE CS 2024 (Forenoon) · Q59Let G = (V, , S, P) be a context-free grammar in Chomsky Normal Form with = \ a, b, c\ and V containing 10 variable symbols including the s…

