


"""simple docstring"""


from __future__ import annotations


def  UpperCAmelCase__	(snake_case__							: Any		,       snake_case__							: str		,       snake_case__							: Optional[Any]   ):
  """simple docstring"""

  if days_between_payments <= 0:
    raise ValueError("""days_between_payments must be > 0"""   )
  if daily_interest_rate < 0:
    raise ValueError("""daily_interest_rate must be >= 0"""   )
  if principal <= 0:
    raise ValueError("""principal must be > 0"""   )
  return principal * daily_interest_rate * days_between_payments


def  UpperCAmelCase__	(snake_case__							: Optional[Any]		,       snake_case__							: Union[str, Any]		,       snake_case__							: Optional[int]		,       ):
  """simple docstring"""

  if number_of_compounding_periods <= 0:
    raise ValueError("""number_of_compounding_periods must be > 0"""   )
  if nominal_annual_interest_rate_percentage < 0:
    raise ValueError("""nominal_annual_interest_rate_percentage must be >= 0"""   )
  if principal <= 0:
    raise ValueError("""principal must be > 0"""   )

  return principal * (
      (1 + nominal_annual_interest_rate_percentage) ** number_of_compounding_periods
      - 1
  )


def  UpperCAmelCase__	(snake_case__							: Optional[Any]		,       snake_case__							: int		,       snake_case__							: Union[str, Any]		,       ):
  """simple docstring"""

  if number_of_years <= 0:
    raise ValueError("""number_of_years must be > 0"""   )
  if nominal_annual_percentage_rate < 0:
    raise ValueError("""nominal_annual_percentage_rate must be >= 0"""   )
  if principal <= 0:
    raise ValueError("""principal must be > 0"""   )

  return compound_interest(
      _A		,       nominal_annual_percentage_rate / 3_65		,       number_of_years * 3_65   )


if __name__ == "__main__":
     import doctest

     doctest.testmod()








"""simple docstring"""


from typing import Any






class  lowercase:







 '''simple docstring'''





 def __init__(    self:		Dict,				a_:		Any		):




   '''simple docstring'''



   _snake_case							:		Dict								=  data
   _snake_case							:		Optional[Any]								=  None







class  lowercase:







 '''simple docstring'''





 def __init__(    self:		str		):




   '''simple docstring'''



   _snake_case							:		Any								=  None


 def 			UpperCamelCase_       (    self:		Any		):




   '''simple docstring'''



   _snake_case							:		List[Any]								=  self.head
   while temp is not None:
     print(temp.data,				end=""" """		)
     _snake_case							:		int								=  temp.next
   print()


 def 			UpperCamelCase_       (    self:		Union[str, Any],				a_:		Any		):




   '''simple docstring'''



   _snake_case							:		Optional[Any]								=  Node(a_		)
   _snake_case							:		Union[str, Any]								=  self.head
   _snake_case							:		List[Any]								=  new_node


 def 			UpperCamelCase_       (    self:		Tuple,				a_:		List[str],				a_:		Union[str, Any]		):




   '''simple docstring'''



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

     _snake_case							:		List[Any]								=  self.head
     while node_a is not None and node_a.data != node_data_a:
       _snake_case							:		List[Any]								=  node_a.next

     if node_a is None or node_a is None:
       return

     _snake_case		, _snake_case							:		int								=  node_a.data, node_a.data


if __name__ == "__main__":
     A_      =    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()


