import math n = int(input()) k = int(math.isqrt(n)) ans = 2 * k if k * (k + 1) > n: ans -= 1 print(ans)