def getMinUnvisited(unvisited, dist):
    """
    return the minimum distance vertex from
    the set of vertices not yet processed.
            
            Parameters:
                    unvisited (set): the set containing all the vertex not yet processed
                    dist (dict): a dictionary with vertex as key and the total distance from the source as value
    """         
    aux = {key: dist[key] for key in unvisited}
    minimum = min(aux.values())
    for key in unvisited:
        if dist[key] == minimum:
            return key