C语言sin()用来计算参数x
的正玄值,然后将结果返回.返回-1
之间的计算结果.
例子:
#include
math.h
main(){
double
answer
=
%f\n",
answer);
}
执行
C语言sin():
sin()原型:double
sin(double
x)
sin()角度与弧度:
扩展资料:
与sin相似的acos函数
函数名:
acos
功
能:计算并返回arccos(x)值、要求-1=X=1
函数与形参类型:
acos(x)
x;
程序例:
stdio.h
int
main(void)
{
result;
x
result
acos(x);
printf("The
arc
cosine
of
%lf
is
%lf\n",
x,
result);
return
0;
参考资料:CSDN博客频道-C语言中sin和cos的用法
首先:程序应该这样改!
main()
n;
b,c;
scanf("%lf",n);
b=sin(n);
c=cos(n);
s;
n,b,c;
scanf("%d",s);
double?sin(double?x);
sin参数为double类型,返回值也为double
#includestdio.h
#includemath.h
int?main()
double?d,?e;
scanf("%f",?d);
printf("%lf\n",?e);
return?0;
以上就是土嘎嘎小编为大家整理的正弦函数值C语言相关主题介绍,如果您觉得小编更新的文章只要能对粉丝们有用,就是我们最大的鼓励和动力,不要忘记讲本站分享给您身边的朋友哦!!