Previous Up Next

5.13.19  Substitute a variable by a value: |

The | operator is infixed. The left hand side is an expression depending on one or more parameters, the right hand side is an equality or several equalities (parameter = value, parameter = value, …).
The | operator returns the expression with the parameters replaced by the given values.
Input:

a^2 + 1 | a = 2

Output (even if a has been assigned a value):

5

Input:

a^2 + b | a = 2, b = 3

Output (even if a or b had been assigned a value):

7

Previous Up Next