
from __future__ import annotations

from typing import Any







class  UpperCamelCase__		:







	'''simple docstring'''





	def __init__(			self				,       UpperCamelCase__ = 6		):
					A__  :	Node | None         =							None
					A__  :	Node | None         =							None
					self.create_linked_list(UpperCamelCase__		)





	def   __snake_case				(			self				,       UpperCamelCase__		):
					A__  :	int         =							Node()
					A__  :	str         =							current_node
					A__  :	List[str]         =							current_node
					A__  :	int         =							current_node
					for _ in range(1				,       UpperCamelCase__		):
									A__  :	Optional[Any]         =							Node()
									A__  :	Optional[Any]         =							current_node
									A__  :	int         =							previous_node
									A__  :	Dict         =							current_node
					A__  :	Dict         =							self.front
					A__  :	str         =							previous_node





	def   __snake_case				(			self		):
					return (
					    self.front == self.rear
					    and self.front is not None
					    and self.front.data is None
					)





	def   __snake_case				(			self		):
					self.check_can_perform_operation()
					return self.front.data if self.front else None





	def   __snake_case				(			self				,       UpperCamelCase__		):
					if self.rear is None:
									return

					self.check_is_full()
					if not self.is_empty():
									A__  :	int         =							self.rear.next
					if self.rear:
									A__  :	Dict         =							data





	def   __snake_case				(			self		):
					self.check_can_perform_operation()
					if self.rear is None or self.front is None:
									return None
					if self.front == self.rear:
									A__  :	Union[str, Any]         =							self.front.data
									A__  :	Optional[int]         =							None
									return data

					A__  :	int         =							self.front
					A__  :	List[str]         =							old_front.next
					A__  :	List[Any]         =							old_front.data
					A__  :	int         =							None
					return data





	def   __snake_case				(			self		):
					if self.is_empty():
									raise Exception('''Empty Queue'''		)





	def   __snake_case				(			self		):
					if self.rear and self.rear.next == self.front:
									raise Exception('''Full Queue'''		)







class  UpperCamelCase__		:







	'''simple docstring'''





	def __init__(			self		):
					A__  :	Any | None         =							None
					A__  :	Node | None         =							None
					A__  :	Node | None         =							None


if __name__ == "__main__":
					import doctest

					doctest.testmod()

def 				SCREAMING_SNAKE_CASE     (      ) ->       Optional[int]:

				"""simple docstring"""







				A__  :	Optional[Any]         =							0
				for i in range(1							,						10_01       ):
								total += i**i
				return str(__UpperCamelCase       )[-10:]


if __name__ == "__main__":
					print(solution())