Advertisement
Guest User

Untitled

a guest
Oct 17th, 2017
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.90 KB | None | 0 0
  1. // lab6for.cpp : Defines the entry point for the console application.
  2. #include "stdlib.h"
  3. #include "stdafx.h"
  4. #include <stdio.h>
  5. #include <iostream>
  6. #include <math.h>
  7. #include <conio.h>
  8. int main(){
  9.     float x;
  10.     float z, n, m; //zminni dla obchuslenna
  11.     float l;
  12.     int p = 0;
  13.         for (x = 2, l = 0; x < 20; x += 0.09, l++) {
  14.             if (l == 0)printf("Shynkler Taras, IT-11, for\n|------------x----------------------result------|\n");
  15.             if (l == 13) {
  16.                 p++;
  17.                 printf("Page:%d Natusnit knopky dla prodovzenna\n",p);
  18.                 l = -1;
  19.                 _getch();
  20.             }
  21.             else {
  22.                 z = sqrt(x);
  23.                 n = tan(z) + sin(x - 3.1);
  24.                 if (n < 0) {
  25.                     printf("------------------------------------------------\n|\t %f \t|\t Minus korin \t|\n ", x);
  26.                 }
  27.                 else {
  28.                     m = pow(n, 1. / 6.);
  29.                     printf("------------------------------------------------\n|\t %f \t|\t %f \t|\n ", x, m);
  30.                 }
  31.             }
  32.         }
  33.     _getch();
  34. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement