import math n = int(input()) ans = 1 base = 1 for i in range(1,101010): if base * base > n: ans = i - 1 break base *= 10 print(ans)