from __future__ import annotations






class 		a__						:

					def __init__(   self				:	List[str],_A				:	int   ):







								"""simple docstring"""






								SCREAMING_SNAKE_CASE_  :		str    				=   data
								SCREAMING_SNAKE_CASE_  :		Any    				=   None







class 		a__						:

					def __init__(   self				:	Any   ):







								"""simple docstring"""






								SCREAMING_SNAKE_CASE_  :		Union[str, Any]    				=   None

					def     __UpperCamelCase       (   self				:	Union[str, Any],_A				:	int   ):







								"""simple docstring"""






								SCREAMING_SNAKE_CASE_  :		List[str]    				=   Node(UpperCamelCase_   )
								SCREAMING_SNAKE_CASE_  :		List[str]    				=   self.head
								SCREAMING_SNAKE_CASE_  :		Optional[int]    				=   new_node
								return self.head.data






					def     __UpperCamelCase       (   self				:	int   ):







								"""simple docstring"""






								SCREAMING_SNAKE_CASE_  :		int    				=   self.head
								SCREAMING_SNAKE_CASE_  :		Optional[int]    				=   self.head
								if self.head:
											while fast_pointer and fast_pointer.next:
														SCREAMING_SNAKE_CASE_  :		Any    				=   fast_pointer.next.next
														SCREAMING_SNAKE_CASE_  :		Any    				=   slow_pointer.next
											return slow_pointer.data
								else:
											print("No element found."   )
											return None


if __name__ == "__main__":
		__lowerCamelCase :     Tuple          =  LinkedList()
		for _ in range(int(input().strip())):
				__lowerCamelCase :     Optional[Any]          =  int(input().strip())
				link.push(data)
		print(link.middle_element())

__lowerCamelCase :     List[Any]          =  {hex(i)[2:]: i for i in range(16)}  # Use [:2] to strip off the leading '0x'




def 				_snake_case     (       lowerCAmelCase							:       str     ):
		"""simple docstring"""







		SCREAMING_SNAKE_CASE_  :		Optional[Any]    				=   hex_string.strip().lower()
		if not hex_string:
				raise ValueError("Empty string was passed to the function"     )
		SCREAMING_SNAKE_CASE_  :		str    				=   hex_string[0] == "-"
		if is_negative:
				SCREAMING_SNAKE_CASE_  :		Optional[int]    				=   hex_string[1:]
		if not all(char in hex_table for char in hex_string     ):
				raise ValueError("Non-hexadecimal value was passed to the function"     )
		SCREAMING_SNAKE_CASE_  :		List[Any]    				=   0
		for char in hex_string:
				SCREAMING_SNAKE_CASE_  :		Tuple    				=   1_6 * decimal_number + hex_table[char]
		return -decimal_number if is_negative else decimal_number


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

		testmod()
