Globals_Sub
Private MyList As List
Activity_Sub 'Just for testing
MyList.Initialize
MyList.AddAll(Array As Int(0,1,2,4,5,6,7,8,9)) 'Adds 0,1,2,4,5,6,7,8,9 to list
Dim ArrayItem As Int = 3 'Item to be added to list
Log(MyList.IndexOf(ArrayItem)) 'See if 3 is already in the list (returns item index or -1)
If MyList.IndexOf(ArrayItem) = -1 Then MyList.Add(ArrayItem) '-1 means not in list, Add 3 to list
For i = 0 To MyList.Size - 1
Log(MyList.Get(i)) 'Show the list in the logs (3 should be at the bottom of the list, hopefully)
Next