from math import isqrt N = int(input()) s = isqrt(N) print(2 * s - int(N // s == s))