Functions

Values dependent on other values

Calculated Values (functions)

Some values are input by the user.

Some values are variable values which can be updated.

One can also define functions, which are values dependent on other values

You can also think of functions as variables which are updated at every step of the Process.

Example: defining a tax function

In Convention, we show an example defining a variable called tax, and using an update variable action to give it a new value after the user enters an amount.

Here we can see a different way of achieving the same thing: defining a function called tax which is dependent on amount

  1. Assume user is asked for an amount (a number) 2. Define function called tax to calculate value based on amount 3. Present the result to the user