MACROMEDIA FLEX-FLEX ACTIONSCRIPT LANGUAGE Reference page 351

Actionscript language reference
Table of Contents

Advertisement

Description
Method; returns the value of the base of the natural logarithm (e), to the power of the exponent
specified in the parameter
Example
The following example displays the logarithm for two number values.
trace(Math.exp(1)); // output: 2.71828182845905
trace(Math.exp(2)); // output: 7.38905609893065
Math.floor()
Availability
Flash Player 5. In Flash Player 4, the methods and properties of the Math class are emulated using
approximations and might not be as accurate as the non-emulated math functions that Flash
Player 5 supports.
Usage
Math.floor(x:Number) : Number
Parameters
A number or expression.
x
Returns
The integer that is both closest to, and less than or equal to, parameter
Description
Method; returns the floor of the number or expression specified in the parameter
the closest integer that is less than or equal to the specified number or expression.
Example
The following code returns a value of 12:
Math.floor(12.5);
The following code returns a value of -7:
Math.floor(-6.5);
Math.log()
Availability
Flash Player 5. In Flash Player 4, the methods and properties of the Math class are emulated using
approximations and might not be as accurate as the non-emulated math functions that Flash
Player 5 supports.
Usage
Math.log(x:Number) : Number
. The constant
x
Math.E
can provide the value of e.
.
x
. The floor is
x
Math.log()
351

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the FLEX-FLEX ACTIONSCRIPT LANGUAGE and is the answer not in the manual?

This manual is also suitable for:

Flex

Table of Contents