Unit -2 Flashcards
(21 cards)
What is Syntax Analysis?
Syntax Analysis is the process of analyzing the syntax of a given input to ensure it conforms to the rules of a formal grammar.
What is the role of the Parser?
The Parser is responsible for analyzing the structure of the input and ensuring it follows the syntax rules defined by the grammar.
What is Syntax Error Handling?
Syntax Error Handling involves detecting and managing errors that occur during the parsing process.
What are Error-Recovery Strategies?
Error-Recovery Strategies are techniques used to recover from syntax errors and continue parsing.
What is Context Free Grammar (CFG)?
Context Free Grammar (CFG) is a type of formal grammar that consists of a set of production rules used to generate strings in a language.
What is a Derivation Tree?
A Derivation Tree is a tree representation of the derivation of a string from a grammar.
What is Left Most Derivation?
Left Most Derivation is a method of deriving a string by always expanding the leftmost non-terminal first.
What is Right Most Derivation?
Right Most Derivation is a method of deriving a string by always expanding the rightmost non-terminal first.
What is Ambiguity in Context Free Grammar?
Ambiguity in Context Free Grammar occurs when a string can be derived in multiple ways, leading to different parse trees.
What is Left Factoring?
Left Factoring is a technique used to eliminate ambiguity by restructuring grammar rules.
What is Parsing?
Parsing is the process of analyzing a string of symbols according to the rules of a formal grammar.
What is Top-Down Parsing?
Top-Down Parsing is a parsing strategy that starts from the root of the parse tree and works down to the leaves.
What is Bottom-up Parsing?
Bottom-up Parsing is a parsing strategy that starts from the leaves of the parse tree and works up to the root.
What is Recursive-Descent Parsing?
Recursive-Descent Parsing is a top-down parsing technique that uses a set of recursive procedures to process the input.
What are Predictive Parsers?
Predictive Parsers are a type of recursive-descent parser that uses lookahead to make parsing decisions.
What is Nonrecursive Predictive Parsing?
Nonrecursive Predictive Parsing is a parsing technique that does not use recursion, often implemented with a stack.
What is the Construction of Predictive Parsing Table?
The Construction of Predictive Parsing Table involves creating a table that guides the parsing process based on lookahead tokens.
What is Left Recursion?
Left Recursion occurs when a non-terminal in a grammar can eventually lead to itself as the leftmost symbol in a production.
What is the Elimination of Left Recursion?
Elimination of Left Recursion is the process of restructuring grammar to remove left recursion, making it suitable for top-down parsing.
What is LL(1) Grammar?
LL(1) Grammar is a type of context-free grammar that can be parsed by a top-down parser using one lookahead token.
What are Heuristics in Error Recovery?
Heuristics in Error Recovery are rules of thumb used to guide the recovery process during syntax error handling.