Limited-time offer! Save up to 50% Off | Solutions starting at $6 each  

Concepts of Programming Language

Added on - 16 May 2020

Trusted by 2+ million users,
1000+ happy students everyday
Showing pages 1 to 4 of 15 pages
Running Head: CONCEPTS OF PROGRAMMING LANGUAGE1Programming Language ConceptsInstitutionDateName
CONCEPTS OF PROGRAMMING LANGUAGE2Chapter 31.Syntax in programming is defined as the form of expressions, program units, andstatements.Semantics, on the other hand, is the meaning of these expressions, program units,and statements (Stroustrup, 2014).2.Language descriptions include the syntax and semantics for every potential user orevaluator that is concerned in knowing and improving their skills in a given programminglanguage3.Semantics and syntax both provides a language’s definition. In a good language, itssemantics follows straightforwardly from the syntax.4.Approaches for formally defining languages:Axiomatic semanticsDenotational semanticsAxiomatic Semantics – An approach which attempts to provide rules that indicate therelevant changes I data immediately after the execution of a feature in a given programminglanguage.Denotational semantics – defines programs basing on mathematical functions and utilizethese functions to obtain the properties of the program (Stroustrup, 2014).5.Language generation mechanismsSyntax: Set of instructions which specify how to write a given programminglanguage.\\Semantics: Relates to the meaning of an instruction e.g. a++.
CONCEPTS OF PROGRAMMING LANGUAGE36.Parse trees and derivation connection is so close. Parse trees or derivations can beconstructed from one another. Derivations that have unambiguous grammar containunique parse trees.7.Values of synthesized attributes are computed basing on the attribute values of childnodes while the value on an inherited attribute is computed basing on the attribute valuesof parent and sibling nodes8.Attribute grammars are used for:Compiler designStatic semantic specification
CONCEPTS OF PROGRAMMING LANGUAGE4Problem Set1.a). Associativity:from left to the right=is right to the left+is left to the right|is left to the right*is left to the rightb). Precedence of operators from high to lowPrecedenceOperator25*6+13|16=c). Left most derivation
You’re reading a preview
Preview Documents

To View Complete Document

Click the button to download
Subscribe to our plans

Download This Document