Difference between revisions of "TIAAppend"
From SCAR Divi Manual
Line 1: | Line 1: | ||
==Definition== | ==Definition== | ||
<source lang="scar" lines="false"> | <source lang="scar" lines="false"> | ||
− | + | function TIAAppend(var TIA: TIntArray; const Int: Integer): Integer; | |
</source> | </source> | ||
==Availability== | ==Availability== | ||
SCAR Divi 3.28 > Current | SCAR Divi 3.28 > Current | ||
+ | |||
+ | * Before 3.34 the function had no result. | ||
==Description== | ==Description== | ||
− | Appends the given [[Integer|integer]] '''Int''' to end of the given TIntArray '''TIA'''. | + | Appends the given [[Integer|integer]] '''Int''' to end of the given TIntArray '''TIA'''. The index of the appended element is returned. |
==Example== | ==Example== | ||
Line 17: | Line 19: | ||
begin | begin | ||
TIA := [0, 1, 3]; | TIA := [0, 1, 3]; | ||
− | TIAAppend(TIA, 4); | + | WriteLn(TIAAppend(TIA, 4)); |
WriteLn(TIAToStr(TIA)); | WriteLn(TIAToStr(TIA)); | ||
end. | end. | ||
Line 23: | Line 25: | ||
Output: | Output: | ||
+ | 3 | ||
0,1,3,4 | 0,1,3,4 | ||
Revision as of 16:27, 23 April 2012
Definition
function TIAAppend(var TIA: TIntArray; const Int: Integer): Integer;
Availability
SCAR Divi 3.28 > Current
- Before 3.34 the function had no result.
Description
Appends the given integer Int to end of the given TIntArray TIA. The index of the appended element is returned.
Example
var TIA: TIntArray; begin TIA := [0, 1, 3]; WriteLn(TIAAppend(TIA, 4)); WriteLn(TIAToStr(TIA)); end.
Output:
3 0,1,3,4