Ответы
Ответ дал:
0
#include<iostream>
#include<cmath>
using namespace std;
int main()
{
double x,S;
int M;
cout << "x = ",cin >> x;
cout << "M = ",cin >> M;
S = 0;
for( int n = 1; n<=M; n++)
{
S += (cos(n*x))/(n*n);
}
cout <<"S = "<<S<<"n";
system("Pause");
return 0;
}
#include<cmath>
using namespace std;
int main()
{
double x,S;
int M;
cout << "x = ",cin >> x;
cout << "M = ",cin >> M;
S = 0;
for( int n = 1; n<=M; n++)
{
S += (cos(n*x))/(n*n);
}
cout <<"S = "<<S<<"n";
system("Pause");
return 0;
}
Вас заинтересует
2 года назад
6 лет назад
6 лет назад
9 лет назад
9 лет назад
9 лет назад