Home
Compiler Design Tutorial, Articles, Programs (Examples)
This section contains tutorials, articles and programs (examples) on compiler design (using LEX). Here, we will learn about Compiler Design, LEX using solved programs (examples).
Latest Articles, Tutorials, Examples on Compiler Design
Tutorials
- Compilers Introduction, Cousins and Phases
- Parsing in Compiler
- Classification of Top Down Parser
- Introduction to Bottom Up Parser
- Operator Precedence Parser
Programs
- LEX Code to identify and print valid Identifier of C/C++ in given Input pattern.
In this article, we going to learn how to create LEX program to analysis whether a input is identifier or not?
- LEX Code to identify and print integer and float value in given Input pattern.
In this article, we going to learn how to create LEX program to analysis whether a input number is integer number or decimal number?
- LEX Code for Tokenizing (Identify and print OPERATORS, SEPARATORS, KEYWORDS, IDENTIFIERS) for the given C fragment.
In this article, we going to learn how to create LEX program to analysis among the given C program which are operators, separators, keywords, identifiers and print on the console?
- LEX Code to count and print the number of total characters, words, white spaces in given ‘Input.txt’ file.
In this article, we going to learn how to create LEX program to analysis how many characters, white space (means \n \t “”), and words are present in given input file?
- LEX Code to replace white spaces of ‘Input.txt’ file by a single blank character into ‘Output.txt’ file.
In this article, we going to learn how to create LEX program to extract multi whitespace and replace with single whitespace?
- LEX Code to remove the comments from any C-Program given at run-time and store into ‘out.c’ file.
In this article, we going to learn how to create LEX program to extract comment (single line and multiline) from c program?
- LEX Code to extract all html tags in the given HTML file at run time and store into Text file given.
In this article, we are going to learn how to create LEX program to extract all HTML tag from HTML file?
- LEX code to replace all the ‘if’ keyword to capital ‘if’ from the given C/C++ file.
In this article, we going to learn how to create LEX program to replace the entire if keyword to capital IF from given C/C++ file?
- LEX Code to count the number of lines, space, tab-meta character and rest of characters in a given Input pattern.
In this article, we going to learn how to create LEX program to analysis how many line, space, tab character and other character are present in given input file?