Main Index : Reference :

var


Description

Declares a variable.

Usage

var variable;
var variable = [any type] value;

Parameters

variable is the name of the variable to be declared.
value is an optional value to assign the variable.

Declaration

var declares a C.O.F.F.E.E. variable. Variables are untyped until they are assigned a value.

Example

// Some examples:

var i;
var x = 5;
var y = 3.0
var a = new(array,4);
var o = new(myClass,3);


// One can declare several variables at one time
// if one separates them with commas.

var i,j;
var a = 5.0, b = 3;

See Also

new(), const