from math import sqrt n=int(input()) s=int(sqrt(n)) if n//s==s: print(s*2-1) else: print(s*2)