Skip to content

Latest commit

 

History

2 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pascal Expression Parser

This program parses math expressions from stdin. Specifically, it parses all expressions with the operators '*', '+', and '(' or ')', and all single-digit numbers. This is defined with the formal grammar:

FILE ::= { LINE } <eof>
LINE ::= EXPRESSION <eoln>
EXPRESSION ::= TERM { ‘+TERM }
TERM ::= FACTOR { ‘*FACTOR }
FACTOR ::= digit | ( ‘(’ EXPRESSION ‘)’ )

Completed for Dr. Rainwater's course COSC 5340—Comparative Study of Programming Languages, in the Fall 2024 Semester at UT Tyler.

About

A basic recursive-descent parser in Pascal.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages