As stated earlier, variables in TBScript are loosely typed. Any variable can contain a 64-bit integer (32 bit for DOS real mode), floating point, or a string value. In addition, a variable can also be contain sub variables using the "dot" syntax or elements using the "bracket" syntax.
// The following line makes a an integer value
a = 452
// This makes it a floating point-value
a = 5.2
// And this one makes it a string
a = "This is a test!"
// These lines creates sub variables of a
a.i = 452
a.f = 5.2
a.s = "This is a test"
// This creates elements of the variable a
a[1] = 452
a[2] = 5.2
Note that any of the statements above will create the named variable if it has not already been created. This is also true when a variable is read.
NOTE: Variables are unique to the current subroutine. Variables in different subroutines with the same name are different variables.