Concepts Of Programming Languages
12th Edition
ISBN: 9780134997186
Author: Sebesta, Robert W.
Publisher: Pearson,
expand_more
expand_more
format_list_bulleted
Textbook Question
Chapter 3, Problem 1PS
The two mathematical models for language description are:
- Recognition
- Generation
These two mathematical models can define the syntax of
Recognition:
- It works on yes or no basis. In this method, a
mechanism called recognition device (R) is used that can read strings from the given alphabet. - This would indicate whether the input string is in language or not. That means, it will either accept the string or reject the string.
- Recognition device filters the correctly formed sentences from those that are incorrectly formed.
- In recognition, recognizer is used for syntax. analysis. Recognizer does not check for all possible strings but it simply check if the given programs are in the language or not.
- It checks the syntactical part of the program.
Generation:
- In this method, a device named generator is used to generate the sentences in a language.
- Whenever a generator is called, it generator a sentence which is unpredictable.
- When a string is to be checked if it is a correct or incorrect, first of all, it calls the generator to generate a correct sentence.
- Then, it compares the correct generated string with the input string.
- Hence, it determines the correction in string.
Expert Solution & Answer
Want to see the full answer?
Check out a sample textbook solutionStudents have asked these similar questions
The String data type is not the same as a basic data type (such as an int, a double, or a Boolean), which are all examples of fundamental data types.
A benefit of evaluating expressions without having to describe language activities is that it is possible to evaluate expressions.
When it comes to evaluating expressions, what are the benefits of being able to do so without having to define actions inside the grammar?
Chapter 3 Solutions
Concepts Of Programming Languages
Ch. 3 - Prob. 1RQCh. 3 - Prob. 2RQCh. 3 - Prob. 3RQCh. 3 - Prob. 4RQCh. 3 - Prob. 5RQCh. 3 - Prob. 6RQCh. 3 - Prob. 7RQCh. 3 - Prob. 8RQCh. 3 - Prob. 9RQCh. 3 - What is the difference between a synthesized and...
Ch. 3 - Prob. 11RQCh. 3 - Prob. 12RQCh. 3 - Prob. 13RQCh. 3 - Prob. 14RQCh. 3 - Prob. 15RQCh. 3 - Prob. 16RQCh. 3 - Prob. 17RQCh. 3 - Prob. 18RQCh. 3 - Prob. 19RQCh. 3 - Prob. 20RQCh. 3 - Prob. 21RQCh. 3 - What does partial correctness mean for a loop...Ch. 3 - Prob. 23RQCh. 3 - Prob. 24RQCh. 3 - Prob. 25RQCh. 3 - Prob. 26RQCh. 3 - Prob. 27RQCh. 3 - Prob. 28RQCh. 3 - Prob. 29RQCh. 3 - The two mathematical models for language...Ch. 3 - Write EBNF descriptions for the following: a. A...Ch. 3 - Prob. 3PSCh. 3 - Prob. 4PSCh. 3 - Prob. 5PSCh. 3 - Prob. 6PSCh. 3 - Prob. 9PSCh. 3 - Prob. 10PSCh. 3 - Prob. 12PSCh. 3 - Prob. 15PSCh. 3 - Prob. 16PSCh. 3 - Prob. 17PSCh. 3 - Prob. 18PSCh. 3 - Compute the weakest precondition for each of the...
Additional Engineering Textbook Solutions
Find more solutions based on key concepts
State whether each of the following is true or false. An algorithm is a procedure for solving a problem in term...
Java How to Program, Early Objects (11th Edition) (Deitel: How to Program)
3.12 (Date Create a class called Date that includes three pieces Of information as data
members—a month (type ...
C++ How to Program (10th Edition)
Show a snippet of PHP code for creating a recordset. Explain the meaning of the code.
Database Concepts (8th Edition)
(TicTacToe Class) Create a class TicTacToe that will enable you to write a complete program to play the game of...
C How to Program (8th Edition)
Describe the values that should he returned from functions that overload relational operators.
Starting Out with C++: Early Objects (9th Edition)
An informal language that has no syntax rules, and is not meant to be compiled or executed is called _____. a. ...
Starting Out with Programming Logic and Design (5th Edition) (What's New in Computer Science)
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Similar questions
- Java language The input of the DFA is a string and output is “accepted" or "rejected". DFA accepts or rejects a string when it reads the final symbol in the string.arrow_forwardExplain how a language's coercion rules effect mistake detection.arrow_forwardCFG Assignment(at least 2 strings must be derive to prove each CFG) Language: of all strings having many 0’s or no zero, defined over {0} Language: of all strings having exactly one 0’s or exactly one 1, defined over {0,1} Language: of all strings having many 0’s or many 1’s or no zero or no one, defined over {0,1} 0*10*arrow_forward
- Describe the effect that a language's coercion rules have on error checking.arrow_forwardDesign DFA for the following language. Each string contains ‘abb’ and has a length greater than 4. Ʃ={a, b}arrow_forwardDesign DFA for the following languages. i. Strings that ends with 0 or ends with only one 0 after reading 1. E=(0, 1} ii. The strings start with 'b' but do not end with 'baa'. E={a, b} iii. Each string contains 'abb' and has a length greater than 4. E={a, b} Design a DFA for the language L where L={ 0'1' both i and j are odd }. For iv. example, 01, 000111, 011111 are valid strings belonging to L. E={0, 1}arrow_forward
- Q = {40, 41, 92, 93} E = {a, b} F = {q0, 41} %3D The start state is go and the transition function is: 8 90 91 92 93 a 91 91 93 93 92 92 93 Draw a state diagram for the DFA M1. What is the language recognized by the DFA M1, L(M1)arrow_forwardARDUINO LANGUAGE We have two push buttons and three LEDs (Red, Green and Blue). When the user presses button 1, the red LED will turn on and the blue LED will turnoff. If the user presses button 1 again the red LED will turn off and the blue LED willturn on. When the user presses button 2, the green LED will blink on and off 3 times. Considera delay of 1 second between blinks.Note: while the green LED is blinking, button 1 may not respond to presses. This is normaland acceptable for your code.arrow_forwardVocabulary Task (C language) Natural language processing (NLP) is a field of artificial intelligence that seeks to develop the ability of a computer program to understand human language. Usually, the first step of an NLP system is to convert words into numeric codes. Thus, the system converts an input text into a sequence of numeric codes before any high-level analysis. This process is known as text preprocessing. We can only perform text preprocessing if we have a vocabulary of words and their associated numeric codes. Your task is to create a vocabulary of unique words for a given text file and assign a different number from 1 to N to each unique word, with N being the total number of unique words. You must perform this assignment so that the first word in alphabetical order gets the number 1, the second word in alphabetical order gets the number 2, and so on. A word is a sequence of letters (uppercase or lowercase). The file is composed of letters and white spaces (spaces, tabs,…arrow_forward
- Data Structure Using C Given a string s containing just the characters '(', ')', '{', '}', '[' and ']', Using C determine if the input string is valid. An input string is valid if: Open brackets must be closed by the same type of brackets. Open brackets must be closed in the correct order. Example 1: Input: s = "()" Output: true Example 2: Input: s = "()[]{}" Output: true Example 3: Input: s = "(]" Output: false Example 4: Input: s = "([)]" Output: false Example 5: Input: s = "{[]}" Output: true note* the previous answered solution had a problem the following input was giving a wrong output Input: s = "([)]" Output: falsearrow_forwardQ = {q0, 91, 92, 93} E = {a,b} F = {q0, 41} %3D The start state is go and the transition function is: 8 90 91 92 93 a 93 93 92 92 93 Draw a state diagram for the DFA M1. What is the language recognized by the DFA M1, L(M1)arrow_forwardAssume Σ = {a, b}. Design a DFA that recognizes the language L, where L contains all strings starting with aaa.arrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- Database System ConceptsComputer ScienceISBN:9780078022159Author:Abraham Silberschatz Professor, Henry F. Korth, S. SudarshanPublisher:McGraw-Hill EducationStarting Out with Python (4th Edition)Computer ScienceISBN:9780134444321Author:Tony GaddisPublisher:PEARSONDigital Fundamentals (11th Edition)Computer ScienceISBN:9780132737968Author:Thomas L. FloydPublisher:PEARSON
- C How to Program (8th Edition)Computer ScienceISBN:9780133976892Author:Paul J. Deitel, Harvey DeitelPublisher:PEARSONDatabase Systems: Design, Implementation, & Manag...Computer ScienceISBN:9781337627900Author:Carlos Coronel, Steven MorrisPublisher:Cengage LearningProgrammable Logic ControllersComputer ScienceISBN:9780073373843Author:Frank D. PetruzellaPublisher:McGraw-Hill Education
Database System Concepts
Computer Science
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:McGraw-Hill Education
Starting Out with Python (4th Edition)
Computer Science
ISBN:9780134444321
Author:Tony Gaddis
Publisher:PEARSON
Digital Fundamentals (11th Edition)
Computer Science
ISBN:9780132737968
Author:Thomas L. Floyd
Publisher:PEARSON
C How to Program (8th Edition)
Computer Science
ISBN:9780133976892
Author:Paul J. Deitel, Harvey Deitel
Publisher:PEARSON
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781337627900
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Programmable Logic Controllers
Computer Science
ISBN:9780073373843
Author:Frank D. Petruzella
Publisher:McGraw-Hill Education
Structured Chart; Author: Tutorials Point (India) Ltd.;https://www.youtube.com/watch?v=vdUO-sGA1DA;License: Standard YouTube License, CC-BY
Introduction to Structure Charts; Author: Christopher Kalodikis;https://www.youtube.com/watch?v=QN2bjNplGlQ;License: Standard Youtube License