4MELFA-BASIC IV
Detailed Explanation of Functions
4-308
Abs
[Function]
Returns the absolute value of a given value.
[Format]
[Reference Program]
1 P2.C=Abs(P1.C)
' P2.C will contain the value of P1.C without the sign.
2 Mov P2
3 M2=-100
4 M1=Abs(M2)
' 100 is assigned to M1.
[Explanation]
(1) Returns the absolute value (Value with the positive sign) of a given value.
[Reference]
<Numeric Variable>=Abs(<Equation>)