Guest User

Untitled

a guest
May 20th, 2018
140
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.24 KB | None | 0 0
  1. # include <iostream>
  2. # include <cmath>
  3. using namespace std;
  4. int main () {
  5.    long long a,c;
  6.    double b;
  7.    cin>>a;
  8.    b=sqrt(a);
  9.    c=b;
  10.    if (c!=b) c++;
  11.    b=round(b);
  12.    a=a-b-c;
  13.    a=a*2+b*3+c*3;
  14.    cout<<a<<endl;
  15.    return 0;
  16. }
Add Comment
Please, Sign In to add comment