






from math import pow, sqrt






def   UpperCamelCase  (       *snake_case__     :   float  ):




     '''simple docstring'''






     __snake_case			:Optional[int]          =						len(snake_case__  ) > 0 and all(value > 0.0 for value in values  )
     return result






def   UpperCamelCase  (       snake_case__     :   float	,snake_case__     :   float  ):




     '''simple docstring'''






     return (
         round(sqrt(molar_mass_a / molar_mass_a  )	,6  )
         if validate(snake_case__	,snake_case__  )
         else ValueError("""Input Error: Molar mass values must greater than 0."""  )
     )






def   UpperCamelCase  (       snake_case__     :   float	,snake_case__     :   float	,snake_case__     :   float  ):




     '''simple docstring'''






     return (
         round(effusion_rate * sqrt(molar_mass_a / molar_mass_a  )	,6  )
         if validate(snake_case__	,snake_case__	,snake_case__  )
         else ValueError(
             """Input Error: Molar mass and effusion rate values must greater than 0."""  )
     )






def   UpperCamelCase  (       snake_case__     :   float	,snake_case__     :   float	,snake_case__     :   float  ):




     '''simple docstring'''






     return (
         round(effusion_rate / sqrt(molar_mass_a / molar_mass_a  )	,6  )
         if validate(snake_case__	,snake_case__	,snake_case__  )
         else ValueError(
             """Input Error: Molar mass and effusion rate values must greater than 0."""  )
     )






def   UpperCamelCase  (       snake_case__     :   float	,snake_case__     :   float	,snake_case__     :   float  ):




     '''simple docstring'''






     return (
         round(molar_mass / pow(effusion_rate_a / effusion_rate_a	,2  )	,6  )
         if validate(snake_case__	,snake_case__	,snake_case__  )
         else ValueError(
             """Input Error: Molar mass and effusion rate values must greater than 0."""  )
     )






def   UpperCamelCase  (       snake_case__     :   float	,snake_case__     :   float	,snake_case__     :   float  ):




     '''simple docstring'''






     return (
         round(pow(effusion_rate_a / effusion_rate_a	,2  ) / molar_mass	,6  )
         if validate(snake_case__	,snake_case__	,snake_case__  )
         else ValueError(
             """Input Error: Molar mass and effusion rate values must greater than 0."""  )
     )










from __future__ import annotations

from collections import deque
from collections.abc import Iterator
from dataclasses import dataclass




@dataclass
class 			snake_case__   :

       '''simple docstring'''
       lowerCamelCase							:				int
       lowerCamelCase							:				int




class 			snake_case__   :

       '''simple docstring'''



       def __init__(							self			,						a__    ) ->      Any:






            '''simple docstring'''





            __snake_case			:list[list[Edge]]          =						[[] for _ in range(a__    )]
            __snake_case			:List[str]          =						size



       def __getitem__(							self			,						a__    ) ->      Iterator[Edge]:






            '''simple docstring'''





            return iter(self._graph[vertex]    )



       @property
       def 					__lowercase						(							self    ) ->      str:






            '''simple docstring'''





            return self._size



       def 					__lowercase						(							self			,						a__			,						a__			,						a__    ) ->      List[Any]:






            '''simple docstring'''





            if weight not in (0, 1):
                 raise ValueError("""Edge weight must be either 0 or 1."""    )

            if to_vertex < 0 or to_vertex >= self.size:
                 raise ValueError("""Vertex indexes must be in [0; size)."""    )

            self._graph[from_vertex].append(Edge(a__			,						a__    )    )



       def 					__lowercase						(							self			,						a__			,						a__    ) ->      int | None:






            '''simple docstring'''





            __snake_case			:Optional[Any]          =						deque([start_vertex]    )
            __snake_case			:list[int | None]          =						[None] * self.size
            __snake_case			:Tuple          =						0

            while queue:
                 __snake_case			:List[Any]          =						queue.popleft()
                 __snake_case			:Optional[Any]          =						distances[current_vertex]
                 if current_distance is None:
                      continue

                 for edge in self[current_vertex]:
                      __snake_case			:Optional[Any]          =						current_distance + edge.weight
                      __snake_case			:Dict          =						distances[edge.destination_vertex]
                      if (
                          isinstance(a__			,						a__    )
                          and new_distance >= dest_vertex_distance
                      ):
                           continue
                      __snake_case			:Dict          =						new_distance
                      if edge.weight == 0:
                           queue.appendleft(edge.destination_vertex    )
                      else:
                           queue.append(edge.destination_vertex    )

            if distances[finish_vertex] is None:
                 raise ValueError("""No path from start_vertex to finish_vertex."""    )

            return distances[finish_vertex]


if __name__ == "__main__":
     import doctest

     doctest.testmod()


