Advertisement
Guest User

Untitled

a guest
Mar 20th, 2018
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.54 KB | None | 0 0
  1. #include "stdafx.h"
  2. #include <iostream>
  3. #include "MathFuncsDll.h"
  4. using namespace std;
  5. void tab(float, float, float);
  6. int main()
  7. {
  8. float a, b, h;
  9. cout << "VVedite a \n";
  10. cin >> a;
  11. cout << "VVedite b \n";
  12. cin >> b;
  13. cout << "VVedite h \n";
  14. cin >> h;
  15. tab(a, b, h);
  16. system("pause");
  17. return 0;
  18. }
  19. void tab(float a, float b, float h){
  20. float f;
  21. int n = (round((b - a)/ h)+ 1);
  22. for (int i = 1; i <= n; i++)
  23. {
  24. f = MathFuncs::MyMathFuncs::func(a);
  25. cout << "x=" << a << " f=" << f << endl;
  26. a = a + h;
  27. }
  28. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement