中国铁道建设出版
int lcm(int a,int b)
{
int i;
i=b;
}
4-5
#include <iostream.h>
#include <math.h>
double sin(double x,double eps)
{
double term,sum,y; int n=1; //n=0 y=x*x; term=x; sum=0; while(fabs(term)>=eps) { sum+=term; n++; term=term*y/((2*n-2)*(2*n-1)); //((2*n)*(2*n-1)) term*=-1; while(i%a)i+=b; return(i);
}
return sum;
}
void main()
{
}
4-6
#include <iostream.h>
#include <math.h>
float solut(float a,float b,float c,float d)
{ double x,y; cout<<"输入x的值(角度):"; cin>>x; while(x>360)x-=360; y=3.1415926*x/180; cout<<"度数为:"<<x<<"其sin值为:"<<sin(y,1e-6)<<'\n';
百度搜索“77cn”或“免费范文网”即可找到本站免费阅读全部范文。收藏本站方便下次阅读,免费范文网,提供经典小说教育文库C++教材练习题参考答案(11)在线全文阅读。
相关推荐: