
lowerCamelCase_						     =					{'''a''': ['''c''', '''b'''], '''b''': ['''d''', '''e'''], '''c''': [], '''d''': [], '''e''': []}
lowerCamelCase_						     =					['''a''', '''b''', '''c''', '''d''', '''e''']






def 						__magic_name__			(   __a      :	Dict	,		__a      :	List[str]	,		__a      :	List[str]						):



     '''simple docstring'''




     UpperCamelCase__				=    start
     # add current to visited
     visited.append(__a						)
     UpperCamelCase__				=    edges[current]
     for neighbor in neighbors:
          # if neighbor not in visited, visit
          if neighbor not in visited:
               UpperCamelCase__				=    topological_sort(__a	,		__a	,		__a						)
    # if all neighbors visited add current to sort
     sort.append(__a						)
     # if all vertices haven't been visited select a new one to visit
     if len(__a						) != len(__a						):
          for vertice in vertices:
               if vertice not in visited:
                    UpperCamelCase__				=    topological_sort(__a	,		__a	,		__a						)
    # return sort
     return sort


if __name__ == "__main__":
    lowerCamelCase_						     =					topological_sort('''a''', [], [])
    print(sort)







def 						__magic_name__			(   __a      :	int	,		__a      :	int						):



     '''simple docstring'''




     while a != 0:
          UpperCamelCase__		,	UpperCamelCase__				=    b % a, a
     return b






def 						__magic_name__			(   __a      :	int	,		__a      :	int						):



     '''simple docstring'''




     if gcd(__a	,		__a						) != 1:
          UpperCamelCase__				=    f"mod inverse of {a!r} and {m!r} does not exist"
          raise ValueError(__a						)
     UpperCamelCase__		,	UpperCamelCase__		,	UpperCamelCase__				=    1, 0, a
     UpperCamelCase__		,	UpperCamelCase__		,	UpperCamelCase__				=    0, 1, m
     while va != 0:
          UpperCamelCase__				=    ua // va
          UpperCamelCase__		,	UpperCamelCase__		,	UpperCamelCase__		,	UpperCamelCase__		,	UpperCamelCase__		,	UpperCamelCase__				=    (ua - q * va), (ua - q * va), (ua - q * va), va, va, va
     return ua % m





