




'''simple docstring'''


import logging
import os

from .state import PartialState

class      A       (						logging.LoggerAdapter       ):







							@staticmethod
							def   __lowerCAmelCase     (    lowerCAmelCase_			:    Union[str, Any]   )     ->				Dict:


														"""simple docstring"""


														_a      	=							PartialState()
														return not main_process_only or (main_process_only and state.is_main_process)







							def   __lowerCAmelCase     (    self			:    Any				,     lowerCAmelCase_			:    List[str]				,     lowerCAmelCase_			:    Tuple				,     *lowerCAmelCase_			:    Dict				,     **lowerCAmelCase_			:    Tuple   )     ->				Any:


														"""simple docstring"""


														if PartialState._shared_state == {}:
																					raise RuntimeError(
																					    '''You must initialize the accelerate state by calling either `PartialState()` or `Accelerator()` before using the logging utility.'''   )
														_a      	=							kwargs.pop('''main_process_only'''				,     lowerCAmelCase_   )
														_a      	=							kwargs.pop('''in_order'''				,     lowerCAmelCase_   )

														if self.isEnabledFor(lowerCAmelCase_   ):
																					if self._should_log(lowerCAmelCase_   ):
																												_a	,				_a      	=							self.process(lowerCAmelCase_				,     lowerCAmelCase_   )
																												self.logger.log(lowerCAmelCase_				,     lowerCAmelCase_				,     *lowerCAmelCase_				,     **lowerCAmelCase_   )

																					elif in_order:
																												_a      	=							PartialState()
																												for i in range(state.num_processes   ):
																																			if i == state.process_index:
																																										_a	,				_a      	=							self.process(lowerCAmelCase_				,     lowerCAmelCase_   )
																																										self.logger.log(lowerCAmelCase_				,     lowerCAmelCase_				,     *lowerCAmelCase_				,     **lowerCAmelCase_   )
																																			state.wait_for_everyone()



def 						snake_case_       (UpperCamelCase			:    str					,		UpperCamelCase			:    str = None ):





							'''simple docstring'''


							if log_level is None:
														_a      	=							os.environ.get('''ACCELERATE_LOG_LEVEL'''					,		UpperCamelCase )
							_a      	=							logging.getLogger(UpperCamelCase )
							if log_level is not None:
														logger.setLevel(log_level.upper() )
														logger.root.setLevel(log_level.upper() )
							return MultiProcessAdapter(UpperCamelCase					,		{} )









'''simple docstring'''



def 				lowercase_					(     __A			:							int      )							->   int:



 """simple docstring"""




 if n == 1 or not isinstance(__A       ,   __A      ):
  return 0
 elif n == 2:
  return 1
 else:
  lowercase       : Tuple						=[0, 1]
  for i in range(2       ,   n + 1      ):
   sequence.append(sequence[i - 1] + sequence[i - 2]      )

  return sequence[n]


def 				lowercase_					(     __A			:							int      )							->   int:



 """simple docstring"""




 lowercase       : List[str]						=0
 lowercase       : str						=2

 while digits < n:
  index += 1
  lowercase       : int						=len(str(fibonacci(__A      )      )      )

 return index


def 				lowercase_					(     __A			:							int = 1_0_0_0      )							->   int:



 """simple docstring"""




 return fibonacci_digits_index(__A      )


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



