Return the tangent of a number (angle):
The result will be:
The tan() method returns a number that represents the tangent of an angle.
![]()
The tan() method is supported in all major browsers.
| Parameter | Description |
|---|---|
| x | Required. A number representing an angle (in radians) |
| Type | Description |
|---|---|
| Number | The tangent of an angle |
| JavaScript Version: | 1.0 |
|---|
Return the tangent of different angles:
The result of a,b,c, and d will be:
JavaScript Math Object
Your message has been sent to W3Schools.