CS6612 COMPILER LAB Manual, COMPILER LABORATORY Manual – CSE 6th SEM Anna University

0

CS6612 COMPILER LAB Manual

Anna University Regulation 2013 Computer Science & Engineering (CSE) CS6612 COMPILER LAB Manual for all experiments is provided below. Download link for IT 6th SEM CS6612 COMPILER LABORATORY Manual is listed down for students to make perfect utilization and score maximum marks with our study materials.

Anna University Regulation 2013 Computer Science & Engineering (CSE) 6th SEM

CS6612 COMPILER LAB-COMPILER LABORATORY Manual

CONSTRUCTION OF NFA
AIM:
To write a program for constructing an NFA from given regular expression using C++.
ALGORITHM:
1. Create a menu for getting four regular expressions input as choice.
2. To draw NFA for a, a/b ,ab ,a* create a routine for each regular expression.
3. For converting from regular expression to NFA, certain transition had been made based on choice of input at the rumtime.
4. Each of the NFA will be displayed is sequential order.
PROGRAM:
#include
#include
#include
struct node
{
char start;
char alp;
node *nstate;
}*p,*p1,*p2,*p3,*p4,*p5,*p6,*p7,*p8;
char e=’e’;
void disp();
void re1() { p1=new(node);
p2=new(node);
p1->start=’0′;
p1->alp=’e’;
p1->nstate=p2;
p2->start=’1′;
p2->alp=’a’;
p2->nstate=NULL;
disp(); getch();
}

void re2() { p1=new(node);
p2=new(node);
p3=new(node);
p4=new(node);
p5=new(node);
p6=new(node);
p7=new(node);
p8=new(node);
CS6612 Compiler Lab Manual with all experiments – Download Here
If you require any other notes/study materials, you can comment in the below section.

Related Links
For CS6612 Compiler Lab Syllabus – Click here
Search Terms
Anna University 6th SEM IT COMPILER LAB Manual
CS6612 COMPILER LABORATORY Manual free download
Anna University IT COMPILER LAB Manual Regulation 2013
CS6612 Manual, COMPILER LAB experiment wise Manual – IT 6th Semester

Share.

Comments are closed.