所属分类:
编译器/解释器
开发工具:C/C++
文件大小:11KB
下载次数:12
上传日期:2005-06-10 13:12:43
说明: 一个简单的词法分析器,1代表字符,2代表关键字(命令字),4带表算符界符, 注:要把wangs.txt这个文件放在桌面上,然后在这个TXT里写上你要识别的语句。然后保存后关毕,在运行WANG词法分析.EXE进行词法分析。 完成识别后,会在相应的词面前出现以上代号。暂不能对数字进行识别。因为在某种请况下数字也可表是为字符……稍有困难,但完成老师的针对程序段:area=b+c*d。那简直是小菜一碟。
(a simple lexical analyzer, a representative character, the two representatives keyword (command word), with four tables operator sector website Note : The wangs.txt the document on the desktop, then the TXT Lane write you to identify words. Then preserved customs Albert, running WANG lexical analysis. EXE for lexical analysis. After completing the identification, in the appropriate words appear in front of the above code. Provisional figures for the right not to identify. Because of the status of requests under certain figures might be for the characters ... the slightest difficulty, but the completion of procedural teachers : area = b, c* d. It is simply to touch.)