Can contain a variable length list of Objects that can be indexed(starting at 0).
array = []
array = [
"element0",
"element1",
true,
11
]
index
to be a numberAdds one or more objects to the array.
array = []
array.Add(true) //Adds true to the array
array.Add(1, 2, 3, "Hello World", null) //Adds those elements to the array
Clears all items from the list
array = [ 1, true, null ]
array.Clear() //Array is now empty
Returns true if the specified array and this array have the same contents
array1 = [
1, 2, 3
]
array2 = [
1, 2, 3
]
if(array1.ContentEquals(array2))
{
//Array Contents are equal
}
Removes the first occurence of one or more elements from the list that are equal to the ones specified.
array = [1, 2, 3]
array.Remove(2) //Array Content: [1, 3]
array.Remove(1, 3) //Array Content: []
Removes one or more elements at the specified indices from the list.
array = [1, 2, 3]
array.RemoveAt(1) //Array Content: [1, 3]
array.RemoveAt(1, 0) //Array Content: []
Reverses the Order of the Elements in the list
array = [1, 2, 3]
array.Reverse() //New Array Order: [ 3, 2, 1 ]
Returns the amount of elements in the list
array = [1, 2, 3]
array.Size() //Returns 3
Swaps two elements in the list.
array = [1, 2, 3]
array.Swap(0, 1) //New Array Order: [2, 1, 3]