This is used to access an element of a list.

var/L[2]  // declares list of size 2
L[1] = 10 // assign first element

If you want to use a datum like a list, you can overload the operator by defining an operator[] proc for reading a value, and operator[]= for writing a value. Those overloads also apply if you use the null-conditional ?[] operator.

See also