


'''simple docstring'''




from __future__ import annotations





class _snake_case :
							"""simple docstring"""





							def __init__( self      ,					__A						)  ->None:



											"""simple docstring"""







											__lowerCamelCase		:   int           =       data
											__lowerCamelCase		:   List[Any]           =       None





class _snake_case :
							"""simple docstring"""





							def __init__( self						)  ->List[Any]:



											"""simple docstring"""







											__lowerCamelCase		:   int           =       None







							def 		__SCREAMING_SNAKE_CASE( self      ,					__A						)  ->int:



											"""simple docstring"""







											__lowerCamelCase		:   Optional[Any]           =       Node(A_						)
											__lowerCamelCase		:   List[str]           =       self.head
											__lowerCamelCase		:   List[Any]           =       new_node
											return self.head.data







							def 		__SCREAMING_SNAKE_CASE( self						)  ->int | None:



											"""simple docstring"""







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


if __name__ == "__main__":
				__lowercase	:   str   		=					LinkedList()
				for _ in range(int(input().strip())):
								__lowercase	:   Any   		=					int(input().strip())
								link.push(data)
				print(link.middle_element())







from __future__ import annotations


def  A			(   lowercase       ,			lowercase					)  ->    int:
		'''simple docstring'''

		UpperCamelCase      ,    UpperCamelCase            =	0, len(lowercase					) - 1
		while start_ind <= end_ind:
				if array[start_ind] == search_item:
						return start_ind
				elif array[end_ind] == search_item:
						return end_ind
				else:
						start_ind += 1
						end_ind -= 1
    # returns -1 if search_item is not found in array
		return -1


if __name__ == "__main__":
					print(double_linear_search(list(range(100)), 40))
