Run ❯
Get your
own
website
Result Size:
625 x 565
×
Change Orientation
Save Code
Change Theme, Dark/Light
Go to Spaces
<!DOCTYPE html> <html> <body> <h1>JavaScript Math</h1> <h2>The Math.tan() Mathod</h2> <p>Math.tan() returns the tangent of a number:</p> <p id="demo"></p> <script> let degrees = 60; let radians = degrees * Math.PI/180; document.getElementById("demo").innerHTML = Math.tan(radians); </script> </body> </html>