assign

assign(x,v) -- assigns v as the value of x.

If the value of x is a symbol or indexed variable, then it can be assigned the value v with

               assign(x,v)
When the value of x is an indexed variable y_i then what happens is that the i-th element of the list y is replaced by v.

Differs from x=v in that here x is evaluated.

Note: it would be better if we could arrange for

               x <- v
to work with indexed variables. See <-.

Go to main index.

Go to concepts index.