bc: Variables
2.2 Variables
=============
Numbers are stored in two types of variables, simple variables and
arrays. Both simple variables and array variables are named. Names
begin with a letter followed by any number of letters, digits and
underscores. All letters must be lower case. (Full alphanumeric names
are an extension. In POSIX 'bc' all names are a single lower case
letter.) The type of variable is clear by the context because all array
variable names will be followed by brackets ( [ ] ).
There are four special variables, SCALE, IBASE, OBASE, and LAST.
SCALE defines how some operations use digits after the decimal point.
The default value of SCALE is 0. IBASE and OBASE define the conversion
base for input and output numbers. The default for both input and
output is base 10. LAST (an extension) is a variable that has the value
of the last printed number. These will be discussed in further detail
where appropriate. All of these variables may have values assigned to
them as well as used in expressions.