This source checks if the operations arithmetics are well made.
It uses an matrix of transitions to know if 2 consecutive characters have consistency or not. Then it revised that all characters written by the user are permitted, (only allow digits, comma, parentheses & operations) Compilate using command gcc of Linux. author: ezequielher
prompt/> gcc lexico.c -o programa
prompt/> ./programa ‘2*3-(56*8.3)’
Show this Source code
0 Responses to “LEXICAL ANALIZER”