"""simple docstring"""


from __future__ import annotations






def      __UpperCAmelCase       (      lowercase		):







  """simple docstring"""
  _UpperCAmelCase    			=   [True] * limit
  _UpperCAmelCase    			=   False
  _UpperCAmelCase    			=   False
  _UpperCAmelCase    			=   True

  for i in range(3 ,int(limit**0.5 + 1		) ,2		):
    _UpperCAmelCase    			=   i * 2
    while index < limit:
      _UpperCAmelCase    			=   False
      _UpperCAmelCase    			=   index + i

  _UpperCAmelCase    			=   [2]

  for i in range(3 ,lowercase ,2		):
    if is_prime[i]:
      primes.append(lowercase		)

  return primes






def      __UpperCAmelCase       (      lowercase = 1_00_00_00		):







  """simple docstring"""
  _UpperCAmelCase    			=   prime_sieve(lowercase		)
  _UpperCAmelCase    			=   0
  _UpperCAmelCase    			=   0

  for i in range(len(lowercase		)		):
    for j in range(i + length ,len(lowercase		)		):
      _UpperCAmelCase    			=   sum(primes[i:j]		)
      if sol >= ceiling:
        break

      if sol in primes:
        _UpperCAmelCase    			=   j - i
        _UpperCAmelCase    			=   sol

  return largest


if __name__ == "__main__":
    print(F'''{solution() = }''')

"""simple docstring"""


from collections.abc import Generator






def      __UpperCAmelCase       (      ):







  """simple docstring"""
  _UpperCAmelCase			,					_UpperCAmelCase    			=   0, 1
  while True:
    _UpperCAmelCase			,					_UpperCAmelCase    			=   b, a + b
    yield b






def      __UpperCAmelCase       (      lowercase = 10_00		):







  """simple docstring"""
  _UpperCAmelCase    			=   1
  _UpperCAmelCase    			=   fibonacci_generator()
  while len(str(next(lowercase		)		)		) < n:
    answer += 1
  return answer + 1


if __name__ == "__main__":
    print(solution(int(str(input()).strip())))
