GATE 2025 set1 · CS · MSQ · 2 marks · Compiler Design › Syntax Analysis (Parsing)
GATE 2025 set1 Computer Science and Information Technology question: Which of the following statement(s) is/are TRUE while computing First and Follow during…
Which of the following statement(s) is/are TRUE while computing First and Follow during top down parsing by a compiler?
- (A)
For a production A→ϵ, ϵ will be added to First(A).
- (B)
If there is any input right end marker, it will be added to First(S), where S is the start symbol.
- (C)
For a production A→ϵ, ϵ will be added to Follow(A).
- (D)
If there is any input right end marker, it will be added to Follow(S), where S is the start symbol.
Show answer
Official answer: A,D
Practise this question with exam-style marking