

import math
from timeit import timeit





def 	snake_case_      (__A     :						int     )			->	int:
   __lowerCAmelCase  :			Union[str, Any]					    =						0
   __lowerCAmelCase  :			Optional[Any]					    =						abs(__A     )
   while True:
      __lowerCAmelCase  :			str					    =						n // 1_0
      digits += 1
      if n == 0:
         break
   return digits





def 	snake_case_      (__A     :						int     )			->	int:
   return 1 if n == 0 else math.floor(math.log(abs(__A     )					,   1_0     ) + 1     )





def 	snake_case_      (__A     :						int     )			->	int:
   return len(str(abs(__A     )     )     )





def 	snake_case_      ()			->	None:
   from collections.abc import Callable

   def benchmark_a_function(__A     :						Callable					,   __A     :						int     ) -> None:
      __lowerCAmelCase  :			Optional[int]					    =						f'''{func.__name__}({value})'''
      __lowerCAmelCase  :			Dict					    =						timeit(f'''__main__.{call}'''					,   setup="""import __main__"""     )
      print(f'''{call}: {func(__A     )} -- {timing} seconds'''     )

   for value in (2_6_2_1_4_4, 1_1_2_5_8_9_9_9_0_6_8_4_2_6_2_4, 1_2_6_7_6_5_0_6_0_0_2_2_8_2_2_9_4_0_1_4_9_6_7_0_3_2_0_5_3_7_6):
      for func in (num_digits, num_digits_fast, num_digits_faster):
         benchmark_a_function(__A					,   __A     )
      print()


if __name__ == "__main__":
   import doctest

   doctest.testmod()
   benchmark()





from .prime_check import Test

Test()


