Absolute (Float function): Difference between revisions

From m204wiki
Jump to navigation Jump to search
mNo edit summary
m (match syntax diagram to revised template; fix tags.)
 
(19 intermediate revisions by 3 users not shown)
Line 1: Line 1:
This [[Intrinsic classes|intrinsic]] function operates on a Float object and returns a number
{{Template:Float:Absolute subtitle}}
that is the absolute value of the method object.
The Absolute function is available as of version 7.3 of the Sirius Mods.


===Absolute syntax===
The <var>Absolute</var> [[Intrinsic classes|intrinsic]] function operates on a <var>Float</var> object and returns a number that is the absolute value of the method object.
    %abs = number:Absolute
====Syntax terms====
<dl>
<dt>%abs<dd>A variable to receive the numeric result of the Absolute method.
<dt>number<dd>A Float value.
</dl>


===Examples===
==Syntax==
The following statement places into %y the absolute value of the number in %x:
{{Template:Float:Absolute syntax}}
    %y = %x:absolute
===Syntax terms===
The following statement returns 6.4 to %y:
<table class="syntaxTable">
    %y = -6.4:absolute
<tr><th>%number</th><td>A variable to receive the numeric result of the <var>Absolute</var> method.</td></tr>
<tr><th>float</th><td>A <var>Float</var> value.</td></tr>
</table>


===See also===
==Usage notes==
[[List of intrinsic Float methods]]
<ul><li>The <var>Absolute</var> function is available as of <var class="product">[[Sirius Mods]]</var> Version 7.3</ul>


==Examples==
<ol><li>The following statement places into %y the absolute value of the number in %x:
<p class="code">%y = %x:absolute
</p>
<li>The following statement returns 6.4 to %y:
<p class="code">%y = -6.4:absolute
</p></ol>


[[Category:Intrinsic Float methods|Absolute function]]
==See also==
[[Category:Intrinsic methods]]
{{Template:Float:Absolute footer}}
[[Category:System methods]]
 
 
<!--
<section begin=dpl_desc />
Absolute value of number
<section end=dpl_desc />
-->

Latest revision as of 06:12, 3 February 2011

Absolute value of a number (Float class)


The Absolute intrinsic function operates on a Float object and returns a number that is the absolute value of the method object.

Syntax

%number = float:Absolute

Syntax terms

%numberA variable to receive the numeric result of the Absolute method.
floatA Float value.

Usage notes

  • The Absolute function is available as of Sirius Mods Version 7.3

Examples

  1. The following statement places into %y the absolute value of the number in %x:

    %y = %x:absolute

  2. The following statement returns 6.4 to %y:

    %y = -6.4:absolute

See also