#include <bits/stdc++.h>
using namespace std;
int main() {
  long long n, ans;
  cin >> n;
  long long h = (long long)sqrt(n);
  ans = h * 2;
  long long g = (h + 1) * (h + 1);
  long long k = h * h;
  if (k == n) {
    cout << ans;
    return 0;
  }
  if (g - n < n - k) {
    ans += 2;
  } else
    ans++;
  cout << ans;
}
