Skip to main content

Introduce Syntax, Semantic and Runtime errors and apply them.

 .

Syntax

Syntax refers to the rules that govern the formation of grammatically correct sentences. Similarly, in computer programming, syntax refers to the rules that govern the structure of the symbols, words and punctuation found in programming language. 

Syntax of a programming language refers to grammatical rules that controls the way in which words, symbols, expression and statements may be formed and combined. The rules that tell us whether a string is a valid program or not, are called the 'syntax' of the language. Let's take an example of English language. The combination of "Subject + Verb + Object" forms a valid English sentence. This rule defines whether a sentence is grammatically correct or not. Different Programming language have some common or different syntax like natural language do.


Semantics

Semantics are the rules that control the meaning. In case of programming language it is defined in terms of what happens when the program is executed. The rules that give meaning to programs are called the 'semantics' of the programming language. The semantics of programming language are much herder to specify than its syntax. No complete satisfactory method for specifying semantics for a programming language has been found.
Semantics is the meaning of a word or phrase. Words have a specific meaning when they are used in a sentence and this meaning can be determined by the context in which they are used. For example, the word "date" can have a specific meaning when used as the subject of a sentence, or it can have a general meaning when used as the object of a sentence.

Runtime Error




Home


Comments

Popular posts from this blog

Important questions of C programming (BCA)

 . What is the characteristics of a good program? Explain types of language processor. Explain any two system design tools. Explain Program Development Life Cycle. Define programing techniques. Different between top-down and button - up approach with suitable example. Difference between cohesion and coupling. Define identifiers, constants, variables and keywords. Explain datatypes. Explain different types of  datatypes available in C. Define operator. Explain its types with suitable example. Explain decision making statement. Explain its type with example. Difference between while, do while loop, for loop. Write a program to find the fibonacci  sequence. What is jumping statement. Explain its types with suitable example.    Write a program to display following:               *               **               ***         ...

BCA Math II old question model solution

 . BCA Math II question model 2018: BCA Math II question model 2019: BCA Math II question model 2020:

BCA mathematics -I (Unit I Set)

 .