Skip to content

Latest commit

 

History

History
12 lines (7 loc) · 752 Bytes

File metadata and controls

12 lines (7 loc) · 752 Bytes

Recursive Descent Parser using Python

This program illustrates how to implement recursive descent parser on a simple grammar using python.

Recursive Descent Parser:

It is a kind of Top-Down Parser. A top-down parser builds the parse tree from the top to down, starting with the start non-terminal. A Predictive Parser is a special case of Recursive Descent Parser, where no Back Tracking is required. By carefully writing a grammar means eliminating left recursion and left factoring from it, the resulting grammar will be a grammar that can be parsed by a recursive descent parser.

Program Features:

  • Read strings from a file and display their status if accepted or rejected.
  • User can insert a string and check its status.