"""simple docstring"""





from __future__ import annotations





def        a_  (   _lowerCAmelCase						:				dict     ,				_lowerCAmelCase						:				str  ):





       '''simple docstring'''

       lowercase__					,   lowercase__    :	int     					=			set(_lowerCAmelCase  ), [start]

       while stack:
              lowercase__    :	Dict     					=			stack.pop()
              explored.add(_lowerCAmelCase  )
              # Differences from BFS:
              # 1) pop last element instead of first one
              # 2) add adjacent elements to stack without exploring them
              for adj in reversed(graph[v]  ):
                     if adj not in explored:
                            stack.append(_lowerCAmelCase  )
       return explored


_UpperCamelCase     :		Tuple											=					{
    "A": ["B", "C", "D"],
    "B": ["A", "D", "E"],
    "C": ["A", "F"],
    "D": ["B", "D"],
    "E": ["B", "F"],
    "F": ["C", "E", "G"],
    "G": ["F"],
}

if __name__ == "__main__":
       import doctest

       doctest.testmod()
       print(depth_first_search(G, "A"))


"""simple docstring"""





import math





def        a_  (   _lowerCAmelCase						:				int = 100  ):





       '''simple docstring'''

       lowercase__    :	Union[str, Any]     					=			sum(i * i for i in range(1     ,				n + 1  )  )
       lowercase__    :	str     					=			int(math.pow(sum(range(1     ,				n + 1  )  )     ,				2  )  )
       return square_of_sum - sum_of_squares


if __name__ == "__main__":
       print(f'''{solution() = }''')

