tsenyaMoLenaane
Appends values to an array.
tsenyaMoLenaane(lenaane, boleng, ...maboleng)Mutates the first array by adding one or more values at its end. Returns the new length, not the array. Passing an array as an item appends that array as one value; it does not flatten it. With no items, the array is unchanged and its length is returned.
Parameters
Section titled “Parameters”| Name | Type | Description |
|---|---|---|
lenaane | lenaane | An array of values. |
boleng | boleng | One or more values to append. |
Examples
Section titled “Examples”tiro setaLoeto() {
thalaKanefase(320, 220);
bokamorago(235);
diri mafelo = [60, 120];
tsenyaMoLenaane(mafelo, 180, 240);
gopheta (diri x mo mafelo) {
thalaSediko(x, 110, 24);
}
emisaPoapoeletso();
}