Working with Variables
Two types of variables can be used in shell programming:
Scalar variables can hold only one value at a time. Array variables can hold multiple values. This section explores the use of both types of variables.
Scalar variables are defined as follows:
Here name is the name of the variable, and value is the value that the variable should hold. For example,
defines the variable FRUIT and assigns it the value peach.
Scalar variables are often referred to as name-value pairs, because a variable's name and its value can be thought of as a pair.