JavaScript Math.tan()
Definition and Usage
The Math.tan() method returns the tangent of a number.
Browser Support
Math.tan()
is an ECMAScript1 (ES1) feature.
ES1 (JavaScript 1997) is fully supported in all browsers:
Chrome | IE | Edge | Firefox | Safari | Opera |
Yes | Yes | Yes | Yes | Yes | Yes |
Syntax
Math.tan(x)
Parameters
Parameter | Description |
---|---|
x | Required. A number, in radians, to find the tangent of. |
Return Value
A number representing the tangent of a number. |