


"""simple docstring"""



from typing import Any







class _lowerCAmelCase       :







   def __init__(			self		,			UpperCamelCase__		):

       '''simple docstring'''




       snake_case					:   List[Any]         =					data
       snake_case					:   str         =					None







class _lowerCAmelCase       :







   def __init__(			self		):

       '''simple docstring'''




       snake_case					:   str         =					None







   def 				lowerCamelCase	(			self		):

       '''simple docstring'''




       snake_case					:   Tuple         =					self.head
       while temp is not None:
           print(temp.data		,			end=" "		)
           snake_case					:   Optional[Any]         =					temp.next
       print()







   def 				lowerCamelCase	(			self		,			UpperCamelCase__		):

       '''simple docstring'''




       snake_case					:   Any         =					Node(UpperCamelCase__		)
       snake_case					:   List[str]         =					self.head
       snake_case					:   Tuple         =					new_node







   def 				lowerCamelCase	(			self		,			UpperCamelCase__		,			UpperCamelCase__		):

       '''simple docstring'''




       if node_data_a == node_data_a:
           return
       else:
           snake_case					:   Any         =					self.head
           while node_a is not None and node_a.data != node_data_a:
               snake_case					:   Optional[Any]         =					node_a.next

           snake_case					:   Optional[Any]         =					self.head
           while node_a is not None and node_a.data != node_data_a:
               snake_case					:   int         =					node_a.next

           if node_a is None or node_a is None:
               return

           snake_case					:   Dict         =					node_a.data, node_a.data


if __name__ == "__main__":
  __snake_case         =					LinkedList()
  for i in range(5, 0, -1):
    ll.push(i)

  ll.print_list()

  ll.swap_nodes(1, 4)
  print("""After swapping""")
  ll.print_list()









"""simple docstring"""



from __future__ import annotations

from cmath import sqrt







def 						__lowerCAmelCase		(		lowercase						:						int		,							lowercase						:						int		,							lowercase						:						int				)			->		tuple[complex, complex]:


    """simple docstring"""





    if a == 0:
        raise ValueError("Coefficient 'a' must not be zero."				)
    snake_case					:   Dict         =					b * b - 4 * a * c

    snake_case					:   Tuple         =					(-b + sqrt(lowercase				)) / (2 * a)
    snake_case					:   Optional[int]         =					(-b - sqrt(lowercase				)) / (2 * a)

    return (
        root_a.real if not root_a.imag else root_a,
        root_a.real if not root_a.imag else root_a,
    )







def 						__lowerCAmelCase		(		)			->		List[Any]:


    """simple docstring"""





    snake_case      ,snake_case					:   Optional[Any]         =					quadratic_roots(a=5		,							b=6		,							c=1				)
    print(F'The solutions are: {solutiona} and {solutiona}'				)


if __name__ == "__main__":
  main()





