def  __lowerCamelCase						(		lowerCAmelCase__      ):






       if len(_SCREAMING_SNAKE_CASE      ) > 1:
              lowerCAmelCase__	      =   len(_SCREAMING_SNAKE_CASE      ) // 2  # Finds the middle of the array
              lowerCAmelCase__	      =   arr[
                  :middle_length
              ]  # Creates an array of the elements in the first half.
              lowerCAmelCase__	      =   arr[
                  middle_length:
              ]  # Creates an array of the elements in the second half.
              lowerCAmelCase__	      =   len(_SCREAMING_SNAKE_CASE      )
              lowerCAmelCase__	      =   len(_SCREAMING_SNAKE_CASE      )
              merge(_SCREAMING_SNAKE_CASE      )  # Starts sorting the left.
              merge(_SCREAMING_SNAKE_CASE      )  # Starts sorting the right
              lowerCAmelCase__	      =   0  # Left Counter
              lowerCAmelCase__	      =   0  # Right Counter
              lowerCAmelCase__	      =   0  # Position Counter
              while (
                  left_index < left_size and right_index < right_size
              ):  # Runs until the lowers size of the left and right are sorted.
                     if left_array[left_index] < right_array[right_index]:
                            lowerCAmelCase__	      =   left_array[left_index]
                            left_index += 1
                     else:
                            lowerCAmelCase__	      =   right_array[right_index]
                            right_index += 1
                     index += 1
              while (
                  left_index < left_size
              ):  # Adds the left over elements in the left half of the array
                     lowerCAmelCase__	      =   left_array[left_index]
                     left_index += 1
                     index += 1
              while (
                  right_index < right_size
              ):  # Adds the left over elements in the right half of the array
                     lowerCAmelCase__	      =   right_array[right_index]
                     right_index += 1
                     index += 1
       return arr


if __name__ == "__main__":
    import doctest

    doctest.testmod()


def 		lowerCAmelCase_     (     _SCREAMING_SNAKE_CASE      ,	_SCREAMING_SNAKE_CASE      ,	_SCREAMING_SNAKE_CASE  )   ->      Dict:

							"""simple docstring"""






							if power < 0:
														return -1
							base %= mod
							_UpperCAmelCase  :			Optional[Any]	       =		1

							while power > 0:
														if power & 1:
																					_UpperCAmelCase  :			Optional[Any]	       =		(result * base) % mod
														_UpperCAmelCase  :			List[str]	       =		power >> 1
														_UpperCAmelCase  :			Optional[int]	       =		(base * base) % mod

							return result




def 		lowerCAmelCase_     (     )   ->      List[str]:

							"""simple docstring"""






							print(modular_exponential(3      ,	2_0_0      ,	1_3  )  )


if __name__ == "__main__":
				import doctest

				doctest.testmod()

				main()




