Function definition: Difference between revisions
→{{header|Frink}}
m (→{{header|Diego}}: syntax) |
|||
Line 1,436:
=={{header|Frink}}==
This function works correctly with any combination of arbitrarily-large integers, arbitrary-precision floating point numbers, arbitrary-size rational numbers, complex numbers, intervals of real numbers, and even numbers with units of measure (e.g. <code>multiply[1 watt, 1 s]</code> gives an answer with dimensions of energy. Frink tries hard to always Do The Right Thing with math and numerics and units of measure.
<lang frink>multiply[x,y] := x*y</lang>
|