def check_if_cluster_is_oversized(cluster_dict, max_nb_build):
    """
    Checks if (at least) one cluster exceeds maximum allowed number of
    buildings nodes.

    Parameters
    ----------
    cluster_dict : dict
        Dictionary with key as cluster number and subgraph (object) as
        value
    max_nb_build : int
        Maximum allowed number of buildings per cluster

    Returns
    -------
    c_size_okay : bool
        True, if cluster sizes are okay. False, if (at least) one cluster
        is too large
    """

    c_size_okay = True  # Assume all sizes are within boundaries
    #  Check cluster_dict for size of every cluster
    for key in cluster_dict:
        if len(cluster_dict[key]) > max_nb_build:
            #  If one cluster is larger than max. value
            #  Set c_size_okay to False
            c_size_okay = False

    return c_size_okay