Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>;
- #include <math.h>;
- using namespace std;
- int main () {
- float a;
- float x;
- cout << "Vvedita a" << '\n';
- cout << "Vvedite x" << '\n';
- cin >> a;
- cin >> x;
- if (abs(x) < 1) {
- float w = a * log(x);
- cout << w;
- }
- if (abs(x) >= 1) {
- if (sqrt(a - pow(x, 2)) >= 0) {
- float w;
- w = sqrt(a - pow(x, 2));
- cout << w;
- }
- else
- cout << "Povtorite popitku";
- }
- }
Add Comment
Please, Sign In to add comment