Compiler Design

Department of Computer Engineering

Technology - That Touches Future Generation!

Smt. S. R. Patel Engineering College- Dabhi (Unjha)

Compiler Design


Laboratory Incharge:
Prof. M. B. Patel
Email:  megha.comp@srpec.org
Phone: +9919601278157

Experiments Performed:

Computer Graphics is a sub-field of computer science which studies methods for digitally synthesizing and manipulating visual content. We perform the practical of various line drawing Algorithm, Clipping Algorithm and Surface Detection Algorithm.

  • • Introduction to LEX
  • • LEX program to show the message when enter key is pressed.
  • • LEX program to check whether the string is in small case letter, uppercase letter or contains mixed letter
  • • LEX program to print the name of the user with message when the enter key is pressed using the function.
  • • LEX program to check whether the given word is vowel or not using the function.
  • • LEX program to recognizes the keyword if, begin and identifier which is defined as any string starts with letter and followed by letter or digit.
  • • Program using LEX to count the number of characters, words, spaces and lines in a given input file.
  • • LEX program to check whether the parenthesis in the statement is missing or not
  • • Lex program which replaces all the occurrances of “rama” with “RAMA” and “sita” with “SITA”. It demonstrates the use of string as a direct pattern in the specification file.
  • • Lex program to count all occurrences of “ rama “ and “ sita “ in a given file.
  • • Introduction to Yacc
  • • Yacc program which identify the language L = Σ, where Σ = {1,0} if and only if the string starts with 10