country
$20 Bonus + 25% OFF
Securing Higher Grades Costing Your Pocket? Book Your Assignment at The Lowest Price Now!
Add File

Error goes here

5129COMP Programming Language Theory

tag 0 Download4 Pages / 762 Words tag Add in library Click this icon and make it bookmark in your library to refer it later. GOT IT
  • Course Code: 5129COMP
  • University: Liverpool John Moores University
  • Country: United Kingdom

Questions: 

Answer any two questions.

1. a. Consider the following Context Free Grammar (CFG), where strings written in italics (clauses, clause, literal_list, literal, op, posneg) denote nonterminals:

 

i. Give two strings which can be derived from the CFG above.

ii. Show a parse tree for the following string derived from the above Context Free Grammar:

“(a ?d)”

iii. Rewrite the CFG to an alternative form so that it is not left-recursive.

b. What is the difference between a compiler and an interpreter?

 

2. a. Rewrite the following infix expression to postfix form:

(3+4)*(7-9)

b. Give two examples of runtime/dynamic semantic checks that may be performed by a compiler for a typical programming language and explain why they cannot be performed statically. 

c. What does it mean for a programming language to be Turing-complete?

d. A particular language contains a floating point numeric type. The following list is of some floating point values in this language (where each float contains a sign, + or -, as well as an ‘f’ character at the end):

+2.5678f

-0.54f

-1.986f

+180.3f

+3.0f

Give a regular expression to denote floating point numbers in this language so that all of the values above would be accepted by your regular expression. If you make any additional assumptions on values permissible as floats, state them after your answer.

e. Compare the advantages and disadvantages of using a Nondeterministic Finite Automaton (an NFA) or a Deterministic Finite Automaton (a DFA) for recognizing strings of a particular language.    

3. a. Consider the following Syntax Directed Translation Scheme (with nonterminals denoted in italics – S, A, B, C, X, pntr, id, digit):

i. Identify the semantic actions of this syntax directed translation scheme.

ii. Write down a parse tree for the following string (where test is an id) and explain what the output would be of the semantic actions when parsing this string:

b. Consider the following Nondeterministic Finite Automaton (NFA):

 

Figure 1 – an NFA

i. Identify the start and final states of the NFA in Figure 1.

ii.For each of the following strings, state whether it would be accepted (recognised) by the NFA of Figure 1:

  • baab
  • babba
  • baaa

iii. Rewrite the NFA of Figure 1 as a Deterministic Finite Automaton (DFA) which accepts the same language (set of strings) 

 

 

Download Sample Now

Earn back the money you have spent on the downloaded sample by uploading a unique assignment/study material/research material you have. After we assess the authenticity of the uploaded content, you will get 100% money back in your wallet within 7 days.

Upload
Unique Document

Document
Under Evaluation

Get Money
into Your Wallet

Total 4 pages, 1 USD Per Page

Cite This Work

To export a reference to this article please select a referencing stye below:

My Assignment Help (2020) Programming Language Theory [Online]. Available from: https://myassignmenthelp.com/free-samples/5129comp-programming-language-theory/nondeterministic-finite-automaton-nfa.html
[Accessed 24 November 2020].

My Assignment Help. 'Programming Language Theory' (My Assignment Help, 2020) <https://myassignmenthelp.com/free-samples/5129comp-programming-language-theory/nondeterministic-finite-automaton-nfa.html> accessed 24 November 2020.

My Assignment Help. Programming Language Theory [Internet]. My Assignment Help. 2020 [cited 24 November 2020]. Available from: https://myassignmenthelp.com/free-samples/5129comp-programming-language-theory/nondeterministic-finite-automaton-nfa.html.


MyAssignmenthelp.com delivers high-quality law assignment help to all students in New Zealand at best possible deal. We have an in-house team of 5000+ native writers who are highly skilled and experts in a wide range of legal topics and subjects. They are thorough with the academic criteria of different law subjects and take a distinct approach to help students understand various complex laws and their applications.

Latest It Write Up Samples

COIT20260 Cloud Computing For Smart Applications

Download : 0 | Pages : 5
  • Course Code: COIT20260
  • University: Central Queensland University
  • Country: Australia

Answer: Introduction The report talks about a business case study, of a company called AB Pty. Ltd. It manages a product delivery business for the area Austin downtown, Texas, USA. This company looks like a small scale business as it contains only three trucks for making the delivery of the products. The products are delivered to the customers of the specified zone. The company is facing a problem in the delivery service which is supposed to ...

Read More arrow

TMED6J1 Child Development And Education

Download : 0 | Pages : 6
  • Course Code: TMED6J1
  • University: University Of Oxford
  • Country: United Kingdom

Answer: It is undeniable that the technological revolution has made itself an essential aspect of our daily lives. It has changed our views of healthcare system, workplace, sports, art, creativity and what not. The rate, in which everyone is using smartphones, tabs and laptops, that it has become difficult to understand whether the person can talk verbally or not. I persoally am a decent user of technology and not always depend upon technologi...

Read More arrow

15DISD205 Digital Diplomacy

Download : 0 | Pages : 3
  • Course Code: 15DISD205
  • University: SOAS University Of London
  • Country: United Kingdom

Answer: Introduction Digital diplomacy is the use of internet resources for the fulfillment of foreign relations on trade issues, communication, media, negotiation, culture and functions (Manor, 2012). ICT as a diplomacy tool supports embassy functions, activities and strategies. A comparative analysis of the Swedish, Maldives, US and Israel embassy modes reveals the use of benefits and risks. The cyberspace has a purpose of promoting meaning...

Read More arrow

ITECH1103 Big Data And Analytics

Download : 0 | Pages : 9
  • Course Code: ITECH1103
  • University: Federation University Australia
  • Country: Australia

Answer: Background: The data analysis of this study finds the “Skills and Credibility” of the students about the fact how they are capable of using the online visualisation tools- “IBM Weston Analytics” (Zhu et al., 2014). Also, their ability to execute the decision analysis and predictive analysis are verified in this research report. The research report is structured on the basis of “Solar city project data&rdq...

Read More arrow

COIT20267 Computer Forensics

Download : 0 | Page : 1
  • Course Code: COIT20267
  • University: Central Queensland University
  • Country: Australia

Answer: Task 1 Scrambled bits using WinHex The WinHex is the tool that is used to change the text content values in hexadecimal format, making some of the strong encryption which can only be decrypted if the right order to reverse operations are being followed. For the current text file, the contents operations are as follows: Select Modify Data->in the new pop up window select the “left shift by 1-bit option” Output: ...

Read More arrow
Next

Save Time & improve Grade

Just share requirement and get customized Solution.

watch
question
We will use e-mail only for:

arrow Communication regarding your orders

arrow To send you invoices, and other billing info

arrow To provide you with information of offers and other benefits

Add File

Error goes here

1,498,900

Orders

4.9/5

Overall Rating

5,100

Experts

Our Amazing Features

delivery

On Time Delivery

Our writers make sure that all orders are submitted, prior to the deadline.

work

Plagiarism Free Work

Using reliable plagiarism detection software, Turnitin.com.We only provide customized 100 percent original papers.

time

24 X 7 Live Help

Feel free to contact our assignment writing services any time via phone, email or live chat. If you are unable to calculate word count online, ask our customer executives.

subject

Services For All Subjects

Our writers can provide you professional writing assistance on any subject at any level.

price

Best Price Guarantee

Our best price guarantee ensures that the features we offer cannot be matched by any of the competitors.

Our Experts

Assignment writing guide
student rating student rating student rating student rating student rating 5/5

1265 Order Completed

97% Response Time

James Cook

Masters in Management

Wellington, New Zealand

Hire Me
Assignment writing guide
student rating student rating student rating student rating student rating 5/5

416 Order Completed

95% Response Time

Tyler Moore

MBA in Accounting

Washington, United States

Hire Me
Assignment writing guide
student rating student rating student rating student rating student rating 5/5

2279 Order Completed

97% Response Time

Zachary Perez

PhD in Computer Science and Information System

Washington, United States

Hire Me
Assignment writing guide
student rating student rating student rating student rating student rating 5/5

265 Order Completed

97% Response Time

Ken Campbell

MSc in Electrical Engineering

Wellington, New Zealand

Hire Me

FREE Tools

plagiarism

Plagiarism Checker

Get all your documents checked for plagiarism or duplicacy with us.

essay

Essay Typer

Get different kinds of essays typed in minutes with clicks.

edit

GPA Calculator

Calculate your semester grades and cumulative GPa with our GPA Calculator.

referencing

Chemical Equation Balancer

Balance any chemical equation in minutes just by entering the formula.

calculator

Word Counter & Page Calculator

Calculate the number of words and number of pages of all your academic documents.

Refer Just 5 Friends to Earn More than $2000

Check your estimated earning as per your ability

1

1

1

Your Approx Earning

Live Review

Our Mission Client Satisfaction

it was really helpful. i got my asssignment on time even before the deadline.it was written really well i am glad that I came to Myassignmenthelp.

flag

User Id: 401534 - 24 Nov 2020

Australia

student rating student rating student rating student rating student rating

very professional i got it before the due time i set, the sheet that was sent to me was very neat and very well done.

flag

User Id: 551988 - 23 Nov 2020

Australia

student rating student rating student rating student rating student rating

Great work! Really appreciate the help and efficiency. Very well organized. Thank you for your help.

flag

User Id: 522859 - 23 Nov 2020

Australia

student rating student rating student rating student rating student rating

given on time. well presented. and very helpful, trust these guys for all your work

flag

User Id: 142836 - 23 Nov 2020

Australia

student rating student rating student rating student rating student rating
callback request mobile
Have any Query?