Scalar variable

from Wikipedia, the free encyclopedia

A scalar variable in the context of programming languages ​​is a variable that stores a single value. The term is based on the mathematical scalar . A scalar data type is the data type of a scalar variable, usually an elementary data type of the programming language used. The counterpart to a scalar variable are arrays , lists and structures , each of which can store several values.

In Pascal , the elementary data types Boolean, Integer, Char, as well as the subrange types of these simple data types and the type Real are summarized under the scalar data types . In Perl , different elementary data types such as integers or strings are mapped using scalar variables .

Web links