Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.
Like in many scripting languages, Lua has variables. You can think of it as something that stores values. When you apply a value to a variable, you can refer to it using the same variable.
An application consists of statements and variables. Statements provide instructions on what operations and computations need to be done. Variables store the values of these computations. Setting a value into a variable is called an assignment.
Lua uses three kinds of variables: global, local, and table fields.