文件名称:analysis
介绍说明--下载内容均来自于网络,请自行研究使用
编写语法分析程序,实现对算术表达式的语法分析。要求所分析算术表达式由如下的文法产生:
E->E+T|E-T|T
T->T*F|T/F|F
F->id|(E)|num
实验要求:在对输入表达式进行分析的过程中,输出所采用的产生式。
编程实现算法4.2,为给定文法自动构造预测分析表。
编程实现算法4.1,构造LL(1)预测分析程序。-Write a parser, parsing arithmetic expressions. Requirements analysis arithmetic expressions generated by the following grammar: E-> E+T | ET | T T-> T* F | T/F | F F-> id | (E) | num experimental requirements: input expression the analysis process, the output generated by the formula. Programming algorithm 4.2 the grammar automatically constructs predictive analysis table given. Programming algorithm 4.1, constructing LL (1) predictive analysis program.
E->E+T|E-T|T
T->T*F|T/F|F
F->id|(E)|num
实验要求:在对输入表达式进行分析的过程中,输出所采用的产生式。
编程实现算法4.2,为给定文法自动构造预测分析表。
编程实现算法4.1,构造LL(1)预测分析程序。-Write a parser, parsing arithmetic expressions. Requirements analysis arithmetic expressions generated by the following grammar: E-> E+T | ET | T T-> T* F | T/F | F F-> id | (E) | num experimental requirements: input expression the analysis process, the output generated by the formula. Programming algorithm 4.2 the grammar automatically constructs predictive analysis table given. Programming algorithm 4.1, constructing LL (1) predictive analysis program.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
analysis.cpp