Lexical-analyzer-and-Grammar Grammar for a subset of c language and a lexical analyzer Open the Terminal. Type g++ lex.yy.c -lfl. Type ./a.out < test.txt. Done.