Advertisement
PavluisBodya

Untitled

Oct 16th, 2019
113
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.37 KB | None | 0 0
  1. #include<iostream>
  2. #include <cmath>
  3. using namespace std;
  4. int main()
  5. {
  6. int n;
  7. int x;
  8. int res;
  9. float *a = new[n];
  10. cout << "Enter n,:";
  11. cin >> n;
  12. cout << "Enter x:";
  13. cin >>x ;
  14. for (int i = 0; i < n; ++i)
  15. {
  16. a[i] = (1 / (i + 1)) + sqrt(abs(x));
  17.  
  18. }
  19. res = (i+1);
  20. for (i = 1; i <= n; i++)
  21. {
  22. res = res * i;
  23. }
  24.  
  25.  
  26.  
  27. system("pause");
  28. return 0;
  29. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement