diff options
Diffstat (limited to 'docs/tutorial/expression.html')
| -rw-r--r-- | docs/tutorial/expression.html | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/docs/tutorial/expression.html b/docs/tutorial/expression.html index 6be69727..ee088ee4 100644 --- a/docs/tutorial/expression.html +++ b/docs/tutorial/expression.html @@ -347,6 +347,7 @@ </tr> </table> +<p>For example, the first expression <code><span class='Number'>3</span> <span class='Function'>×</span><span class='Modifier'>˜</span><span class='Modifier2'>∘</span><span class='Function'>+</span> <span class='Number'>4</span></code> expands to <code><span class='Function'>×</span><span class='Modifier'>˜</span> <span class='Number'>3</span> <span class='Function'>+</span> <span class='Number'>4</span></code>. Summing up, we get <code><span class='Function'>×</span><span class='Modifier'>˜</span> <span class='Number'>7</span></code>, which from the previous section is <code><span class='Number'>7</span> <span class='Function'>×</span> <span class='Number'>7</span></code>, or <code><span class='Number'>49</span></code>.</p> <p>It's past time we covered how the syntax for modifiers works. Remember how I told you you hated learning the order of operations? No? Good. Modifiers bind more tightly than functions, so they are called on their operands before those operands can be used as arguments. As the parentheses above suggest, modifiers associate from left to right, the opposite order as functions. For example, the first expression above is evaluated in the order shown below. First we construct the square function <code><span class='Function'>×</span><span class='Modifier'>˜</span></code>, then compose it with <code><span class='Function'>+</span></code>, and finally apply the result to some arguments.</p> <svg viewBox='-212.64 -34 512 134'> <g font-family='BQN,monospace' font-size='18px' class='Paren' fill='currentColor'> |
