Quick actions

cmd+k|ctrl+k

Navigation

Languages

Lab 5

Snippet info

Language

Cpp

Visibility

public

Author

sergey

Created

2019-10-26T17:11:24Z

Updated

2019-10-26T17:11:24Z

#include <iostream>
#include <cmath>
using namespace std;

int main() {
    int x, b = 1;
    double a = 0.5, y, h;
    for (int i = 1; i <= 7; i++)
    {
        cin>>x;
        h = 2 * a * b - x;
        y = (pow(cos(2 * x), 3) - pow(sin(3 * x), 2)) / h;
        if(h!=0){cout << "x = " << x << "  --->  " << "y = " << y << endl;}
        else {cout << "При х = "<<x<<" график не существует" << endl;}
    }
    
    
    return 0;
}
INFO