Menu
   ❮   
HTML CSS JAVASCRIPT SQL PYTHON JAVA PHP HOW TO W3.CSS C C++ C# BOOTSTRAP REACT MYSQL JQUERY EXCEL XML DJANGO NUMPY PANDAS NODEJS R TYPESCRIPT ANGULAR GIT POSTGRESQL MONGODB ASP AI GO KOTLIN SASS VUE DSA GEN AI SCIPY CYBERSECURITY DATA SCIENCE
     ❯   

C Math acos() Function

❮ Math Functions


Example

Return the arccosine of different numbers:

printf("%f", acos(0.64));
printf("%f", acos(-0.4));
printf("%f", acos(0));
Try it Yourself »

Definition and Usage

The acos() function returns the arccosine of a number in radians.

The acos() function is defined in the <math.h> header file.


Syntax

One of the following:

acos(double number);

Parameter Values

Parameter Description
number Required. A number to find the arccosine of, in the range -1 to 1. If the value is outside -1 to 1, it returns NaN (Not a Number).

Technical Details

Returns: A double value representing the arccosine of a number in radians.

❮ Math Functions


Related Pages

C Functions Tutorial

C Math Functions Tutorial