Advertisement
Rofyda_Elghadban1

Untitled

Dec 2nd, 2021
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. #include <iostream>
  2. #include <iomanip>
  3. #include <cmath>
  4.  
  5. using namespace std;
  6.  
  7. void Rofyda_Elghadban(){
  8. #ifndef ONLINE_JUDGE
  9. freopen("input.txt", "r", stdin), freopen("output.txt", "w", stdout);
  10. #endif
  11. }
  12.  
  13. int main()
  14. { Rofyda_Elghadban();
  15. float A, B, floor, ceil, round;
  16. cin >> A>> B;
  17. cout<<"floor "<<A<<" / "<<B<<" = "<<floor(A/B) <<"\n";
  18. cout<<"ceil "<<A<<" / "<<B<<" = "<<ceil(A/B) <<"\n";
  19. cout<<"round "<<A<<" / "<<B<<" = "<<round(A/B) <<"\n";
  20. return 0;
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement