What is Semantics? Semantics in Programming Language

Semantics is also called semiotics, semology or semasiology, the philosophical and scientific study of meaning in natural and artificial languages. The term is one of a group of English words formed from the various derivatives of the Greek verb semaino which means “to mean” or “to signify”. The noun semantics and the adjective semantic are derived from sēmantikos “significant” semiotics adjective and noun comes from sēmeiōtikos “pertaining to signs” semiology from sēma “sign” + logos “account” and semasiology from sēmasia “signification”+ logos.

It is concerned with the relationship between signifiers like words, phrases, signs, and symbols—and what they stand for in reality, their denotation. The formal study of semantics intersects with many other fields of inquiry, including lexicology, syntax, pragmatics, etymology and others. Independently, semantics is also a well-defined field in its own right, often with synthetic properties. In the philosophy of language, semantics and reference are closely connected. Further related fields include philology, communication, and semiotics. The formal study of semantics can therefore be manifold and complex.

In programming language theory, semantics is the field concerned with the rigorous mathematical study of the meaning of programming languages. It does so by evaluating the meaning of syntactically valid strings defined by a specific programming language, showing the computation involved. In such a case that the evaluation would be of syntactically invalid strings, the result would be non-computation. It describes the processes a computer follows when executing a program in that specific language. This can be shown by describing the relationship between the input and output of a program, or an explanation of how the program will be executed on a certain platform, hence creating a model of computation.