format
typescript
List.AddRange(objects)class: List
description
Add a group of elements to the list.
parameter
| param_name | type | description |
|---|---|---|
| objects | T[]List<T> | The group of elements. |
reture
| type | description |
|---|---|
void |
code example
typescript
let list = new List<Number>(Number);
// Add a group of elements to the list.
list.AddRange([100, 200]);
for (let index = 0; index < list.count; index++) {
Debug.Log(list.get(index));// Output the elements in the list.
}