import math def main(): N = int(input()) if N == 1: print(0) return n = math.log2(N) if not n % 1: print(int(n)) else: n = int(n + 1) x = 2 ** n while x > N: x -= 1 n += 1 print(n) main()