JavaScript Reference/Javascript Objects/Math
Содержание
"Math" Example
<html>
<body>
<script language="javascript">
function function1(){
alert(Math.max(2, 4));
}
</script>
<button onclick="function1();">
Math function returns greater of 2 numbers (2 or 4)
</button>
</body>
</html>
"Math" JavaScript Methods
+----------------+--------------------------------------------------------------+
| JavaScript |abs acos |
| Methods |asin atan |
| |atan2 ceil |
| |cos exp |
| |floor log |
| |max min |
| |pow random |
| |round sin |
| |sqrt tan |
+----------------+--------------------------------------------------------------+
"Math" JavaScript Properties
+----------------+--------------------------------------------------------------+
| JavaScript |constructor E |
| Properties |LN10 LN2 |
| |lOG10E lOG2E |
| |PI SQRT1_2 |
| |SQRT2 |
+----------------+--------------------------------------------------------------+
"Math" Syntax and Note
Note:
Mathematical operations.
Syntax:
Math.memberName