Math.atan method
The Math.atan method returns
the arctangent of a number. The method
parameter must be between -Pi/2
and Pi/2, otherwise NaN
will be returned.
Syntax
javascriptMath.atan(number);
Example
Let's output the arctangent of
the number 2:
javascriptconsole.log(Math.atan(2));
The code execution result:
javascript1.1071487177940904