
'''simple docstring'''







from copy import deepcopy






class  lowerCAmelCase__   :






					def __init__(   self				,							__SCREAMING_SNAKE_CASE = None				,							__SCREAMING_SNAKE_CASE = None		):


											"""simple docstring"""





											if arr is None and size is not None:
																	lowercase_	:     List[Any]													=       size
																	lowercase_	:     Any													=       [0] * size
											elif arr is not None:
																	self.init(__SCREAMING_SNAKE_CASE		)
											else:
																	raise ValueError('''Either arr or size must be specified'''		)






					def 	_snake_case    (   self				,							__SCREAMING_SNAKE_CASE		):


											"""simple docstring"""





											lowercase_	:     Optional[Any]													=       len(__SCREAMING_SNAKE_CASE		)
											lowercase_	:     Tuple													=       deepcopy(__SCREAMING_SNAKE_CASE		)
											for i in range(1				,							self.size		):
																	lowercase_	:     List[str]													=       self.next_(__SCREAMING_SNAKE_CASE		)
																	if j < self.size:
																							self.tree[j] += self.tree[i]






					def 	_snake_case    (   self		):


											"""simple docstring"""





											lowercase_	:     Tuple													=       self.tree[:]
											for i in range(self.size - 1				,							0				,							-1		):
																	lowercase_	:     Dict													=       self.next_(__SCREAMING_SNAKE_CASE		)
																	if j < self.size:
																							arr[j] -= arr[i]
											return arr






					@staticmethod
					def 	_snake_case    (   __SCREAMING_SNAKE_CASE		):


											"""simple docstring"""





											return index + (index & (-index))






					@staticmethod
					def 	_snake_case    (   __SCREAMING_SNAKE_CASE		):


											"""simple docstring"""





											return index - (index & (-index))






					def 	_snake_case    (   self				,							__SCREAMING_SNAKE_CASE				,							__SCREAMING_SNAKE_CASE		):


											"""simple docstring"""





											if index == 0:
																	self.tree[0] += value
																	return
											while index < self.size:
																	self.tree[index] += value
																	lowercase_	:     Optional[int]													=       self.next_(__SCREAMING_SNAKE_CASE		)






					def 	_snake_case    (   self				,							__SCREAMING_SNAKE_CASE				,							__SCREAMING_SNAKE_CASE		):


											"""simple docstring"""





											self.add(__SCREAMING_SNAKE_CASE				,							value - self.get(__SCREAMING_SNAKE_CASE		)		)






					def 	_snake_case    (   self				,							__SCREAMING_SNAKE_CASE		):


											"""simple docstring"""





											if right == 0:
																	return 0
											lowercase_	:     Tuple													=       self.tree[0]
											right -= 1  # make right inclusive
											while right > 0:
																	result += self.tree[right]
																	lowercase_	:     Optional[Any]													=       self.prev(__SCREAMING_SNAKE_CASE		)
											return result






					def 	_snake_case    (   self				,							__SCREAMING_SNAKE_CASE				,							__SCREAMING_SNAKE_CASE		):


											"""simple docstring"""





											return self.prefix(__SCREAMING_SNAKE_CASE		) - self.prefix(__SCREAMING_SNAKE_CASE		)






					def 	_snake_case    (   self				,							__SCREAMING_SNAKE_CASE		):


											"""simple docstring"""





											return self.query(__SCREAMING_SNAKE_CASE				,							index + 1		)






					def 	_snake_case    (   self				,							__SCREAMING_SNAKE_CASE		):


											"""simple docstring"""





											value -= self.tree[0]
											if value < 0:
																	return -1

											lowercase_	:     Tuple													=       1  # Largest power of 2 <= size
											while j * 2 < self.size:
																	j *= 2

											lowercase_	:     int													=       0

											while j > 0:
																	if i + j < self.size and self.tree[i + j] <= value:
																							value -= self.tree[i + j]
																							i += j
																	j //= 2
											return i


if __name__ == "__main__":
							import doctest

							doctest.testmod()





'''simple docstring'''




def 		lowerCAmelCase_				(   snake_case__ = 10						):




    '''simple docstring'''



    if not isinstance(snake_case__		,				snake_case__						) or n < 0:
        raise ValueError('''Invalid input'''						)
    A       :   List[str]					=						10**n
    A       :   Tuple					=						2_8433 * (pow(2		,				783_0457		,				snake_case__						)) + 1
    return str(number % modulus						)


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

      testmod()
      print(f'''{solution(10) = }''')




