Write my Essay on programming langauge

A compiler converts a source language program into a target language program. There are some basic stages in compilation process, including scanning, parsing, semantic analysis, and code generation. For this assignment, you will implement a scanner and parser for a small language with its grammar given in BNF notation. The language literals are enclosed with ‘ ‘ in the CFG below

Context Free Grammar: -> ‘end’
->|
-> ID ‘=’
|’read’ ID
|’write’
-> {(‘+’|’-‘)}
-> {(‘*’|’/’) }
-> ID
| INT_CONSTANT
|'(‘‘)’

The possible set of tokens, represented with regular expressions, includes:

ASSIGN -> =
PLUS -> +
MINUS -> –
TIMES -> *
DIV -> /
LPAREN ->(
RPAREN -> )
ID -> letter(letter|digit)*
Except read, write, and end.
INT_CONSTANT -> digit digit*
LETTER ->[a-zA-Z]
DIGIT ->[0-9]
Your task is to implement a scanner and a parser for this simple language.

Miscellaneous:

1. You may use any language of your choice to write your program. However, your program must compile and run on pluto.
2. Programs can be read from keyboard instead of file.
3. Sample runs can be found in hw2 (will be provided later).
Submission notes
1. All your source code
2. Brief documentation or readme file (i.e. no more than a page), to include the following
a. Instructions on how to build and execute your program
b. Any difficulties you encountered in designing/writing your program
c. What you learn/find from or reflection of this assignment.

The post programming langauge appeared first on Essaysholic.

Would you like to get in touh with us?
Contact Us

Is this question part of your Assignment?

We can help

Our aim is to help you get A+ grades on your Coursework.

We handle assignments in a multiplicity of subject areas including Admission Essays, General Essays, Case Studies, Coursework, Dissertations, Editing, Research Papers, and Research proposals

Header Button Label: Get Started NowGet Started Header Button Label: View writing samplesView writing samples