N = int(input()) bsc = 1 slaps = 0 while bsc != N: if bsc > N: bsc -= 1 continue bsc *= 2 slaps += 1 print(slaps)