We'll begin with a discussion of ksh variables and arithmetic. Be aware that, as mention last class, many of these topics are covered in Chapter 10, due to ksh 's inherent similarities with the Bourne Shell.
Variables are assign numeric values with the use of the let command.
Variable Substitution ksh also supports variable substitution, which allows you to both use and modify variable values at the same time, as well as providing a default value. If variable is not set, the value of the expression is interpreted as default . The colon is optional, but if it's included variable must not only set but not null to be interpreted as having a value. IOW if you have the expression above and variable is set, but has a null value, the value of the expression is default . Other substitutions are listed below.