def _opt_query_iteration(self, var_nq: int, var_t: int, lambda_param: float) -> tuple[list[int], int]:
        """
        Determine optimal distribution of number of queries.
        """
        coefficients = [lambda_param ** (-2 * i / 3) for i in range(0, var_t)]
        sum_coefficients = sum(coefficients)
        opt_q = [round(var_nq * coefficients[i] / sum_coefficients) for i in range(0, var_t)]

        if opt_q[0] > 80:
            var_t = var_t + 1
            opt_q, var_t = self._opt_query_iteration(var_nq, var_t, lambda_param)
        elif opt_q[0] < 50:
            var_t = var_t - 1
            opt_q, var_t = self._opt_query_iteration(var_nq, var_t, lambda_param)

        return opt_q, var_t

        Determine optimal distribution of number of queries.
        
art/attacks/evasion/geometric_decision_based_attack.py