C Tutorial/math.h/tan
tan
Item Value Header file math.h Declaration float tanf(float arg);double tan(double arg);long double tanl(long double arg); Return returns the tangent of arg. Parameter The value of arg must be in radians.
#include <math.h>
#include <stdio.h>
int main(void)
{
double val = -1.0;
do {
printf("Tangent of %f is %f.\n", val, tan(val));
val += 0.1;
} while(val<=1.0);
return 0;
}