• Method:
• Parser verifies that the string of
tokens
represents a syntactically well-formed program
• If it finds a parse tree for the string, it is
correct; otherwise, it is not
• Construction of tree is based on
grammatical
rules
• Two approach: top-down and bottom-up