IBitArray.Length

Syntax

Length: Integer;

Description

The Length property determines bit array size.

Example

Sub Main;

Var

BitArr: IBitArray;

i: Integer;

Begin

BitArr:=New BitArray.Create;

BitArr.Length:=15;

For i:=0 To BitArr.Length-1 Do

If Math.Round(Math.Rand,0)=1 Then

BitArr.Item(i):=True;

Else

BitArr.Item(i):=False;

End If;

End For;

End Sub Main;

After executing the example a bit array that contains 15 elements is generated.

See also:

IBitArray