#include <iostream>
#include <cmath>
#include <iomanip>
using namespace std;
int main()
{
setlocale(LC_ALL, "Rus");
double a = -2, b = -0.1, x, s, h, y, t, q;
h = (b - a) / 10;
int n;
for (x = a; x <= b; x += h)
{
y = x * cos(x);
s = x;
t = x;
q = -x * x;
for (n = 1; n < 141; n++)
{
t = t * q / (2 * n * (2 * n - 1));
s += t;
}
cout << "y= " << y << setw(12) << "s= " << s << endl;
}
}