



"""simple docstring"""







def 				UpperCamelCase_    (    lowerCAmelCase__      :				Union[str, Any]						)						->   str:

  """simple docstring"""




  if not all(char in '01' for char in bin_string						):
    raise ValueError('Non-binary value was passed to the function'						)
  if not bin_string:
    raise ValueError('Empty string was passed to the function'						)
  lowerCAmelCase_   :				int								= ''
  while len(_lowerCAmelCase						) % 3 != 0:
    lowerCAmelCase_   :				str								= '0' + bin_string
  lowerCAmelCase_   :				Union[str, Any]								= [
      bin_string[index : index + 3]
      for index in range(len(_lowerCAmelCase						)						)
      if index % 3 == 0
  ]
  for bin_group in bin_string_in_3_list:
    lowerCAmelCase_   :				Tuple								= 0
    for index, val in enumerate(_lowerCAmelCase						):
      oct_val += int(2 ** (2 - index) * int(_lowerCAmelCase						)						)
    oct_string += str(_lowerCAmelCase						)
  return oct_string


if __name__ == "__main__":
     from doctest import testmod

     testmod()










'''simple docstring'''





from __future__ import annotations

import math
from collections.abc import Callable

def        a_     (							_lowerCAmelCase       ,_lowerCAmelCase       ,_lowerCAmelCase       ,_lowerCAmelCase = 100       ,)      ->      float:
  __lowerCamelCase       :       Dict           = x_start
  __lowerCamelCase       :       int           = fnc(_lowerCAmelCase       )
  __lowerCamelCase       :       Dict           = 0.0

  for _ in range(_lowerCAmelCase       ):
    # Approximates curve as a sequence of linear lines and sums their length
    __lowerCamelCase       :       List[str]           = (x_end - x_start) / steps + xa
    __lowerCamelCase       :       List[Any]           = fnc(_lowerCAmelCase       )
    length += math.hypot(xa - xa       ,fxa - fxa       )

    # Increment step
    __lowerCamelCase       :       Any           = xa
    __lowerCamelCase       :       Tuple           = fxa

  return length


if __name__ == "__main__":

   def        a_     (							_lowerCAmelCase       )      ->      Dict:
     return math.sin(10 * x       )

   print('f(x) = sin(10 * x)')
   print('The length of the curve from x = -10 to x = 10 is:')
   _UpperCamelCase											=						10
   while i <= 100000:
      print(f'''With {i} steps: {line_length(f, -10, 10, i)}''')
      i *= 10






