JS Built-ins
← Math70 / 215
Mathatanbeginner

Math.atan() Always Returns a Number

πŸ“– Usage Example
// Inverse tangent β€” result in radians
Math.atan(1)   // β†’ 0.7853... (Ο€/4)
Math.atan(0)   // β†’ 0

Use Math.atan() to find the angle (in radians) whose tangent equals a given value.

Math.atan(x)

Math.atan() is defined for all real numbers and always returns a number.

Challenge: Verify the return type of Math.atan() for various inputs.

πŸ’‘ Hints (2)
  • β€’ All Math methods return a number primitive
  • β€’ atan accepts any real number including Β±Infinity