Quick actions

cmd+k|ctrl+k

Navigation

Languages

Вариант 21

Snippet info

Language

Cpp

Visibility

public

Author

sergey

Created

2019-09-16T06:08:20Z

Updated

2019-09-16T06:08:20Z

#include <iostream>
#include <cmath>
using namespace std;
                           
int main() 
{
    double x, k, Z;
    cout << "Вариант 21" << endl;
    //cout << "Введите x" << endl;
    cin >> x;
    k = 1 + pow(x ,2);
    setlocale(LC_ALL,"Russian");
    if (k <= 0) {Z = 2 * cos(3*x)/sin(3*x) ;}
    else { 
        if (cos (x) == 0) {cout << "Решений нет";} 
        else { Z = 2 * cos(3*x)/sin(3*x) - log(cos(x)) / log (k) ;}
        ;}
        cout << "Z = " << Z << endl;
    return 0;
}
INFO