Advertisement
erfanul007

CF B

Jan 5th, 2019
200
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.19 KB | None | 0 0
  1. #include<bits/stdc++.h>
  2. #include<cmath>
  3. using namespace std;
  4. int main()
  5. {
  6. int n,x,y;
  7. cin>>n;
  8. x=ceil(sqrt((double)n));
  9. y=ceil((double)n/x);
  10. cout<<x+y<<endl;
  11. return 0;
  12. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement