Skip to content

Shijin-GitH/Compiler-Lab-S7-Programs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Hello there!

This programs in this repository are tailored for exam purpose. In order to reduce the size of code and to reduce the complexity, error handling and other edge cases are not handled in these programs.

So if in any of the programs you find no output ( provided the input is correct and given in the correct format ), please try adding error handling and other edge cases as per your requirement.

Instruction to Run YACC Programs

These set of codes use a combination of LEX and YACC to perform lexical analysis and parsing.

Both LEX and YACC are tools used in compiler construction to generate lexical analyzers and parsers, respectively. So both files are required to run the program successfully.

To run YACC programs, follow these steps:

  • yacc -d .y
  • lex .l
  • gcc y.tab.c lex.yy.c
  • ./a.out

Instruction to Run Only LEX Programs

These set of codes use LEX to perform lexical analysis.

To run LEX programs, follow these steps:

  • lex .l
  • gcc lex.yy.c
  • ./a.out

Instruction to Run C Programs

These set of codes are written in C programming language.

To run C programs, follow these steps:

  • gcc .c
  • ./a.out

Star the repository if you find it useful!

About

This repository contains exam oriented short and not too complex codes for S7 Compiler Lab

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors