Dynamic programming: how to solve a problem with multiple constraints?
The practical solution is to formulate this as an instance of integer linear programming and apply an ILP solver.  There will be a clean formulation as ILP, and it might work pretty well.  For each item, you have an associated variable $v_i$ that is zero or one according to whether item $i$ is included in the basket or not (one means that it is included); then every one of your requirements can be expressed as a linear inequality on the $v_i$'s.

For example, the requirement that you have exactly $c$ items in the basket corresponds to the linear equality

$$v_1 + v_2 + \dots + v_n = c.$$

The requirement that min(avg(w), avg(x), avg(y)) > d is equivalent to the requirements that the sum of the $w$-fields is at least $c \times d$, and the sum of the $x$-fields is at least $c \times d$, and the sum of the $y$-fields is at least $c \times d$.  The former can be expressed as

$$w_1 \cdot v_1  + w_2 \cdot v_2 + \dots + w_n \cdot v_n &gt; c \times d,$$

where $w_i$ is the value of the $w$-field for the $i$th possible item.  Note that $w_1,\dots,w_n,c,d$ are all constants (known from the problem statement), and $v_1,\dots,v_n$ are the variables, so this is a linear inequality.  Similarly for the sum of the $x$-fields and $y$-fields.

Finally, the goal of maximizing the average of the $z$-fields is equivalent to maximizing the sum of the $z$-fields of the selected items.  This corresponds to maximizing the following (linear) objective function:

$$z_1 \cdot v_1 + \dots + z_n \cdot v_n.$$

All of these are linear.  Finally, you can express the requirement that each $v_i$ must be either 0 or 1 by adding linear inequalities $0 \le v_i \le 1$ and requiring that $v_i$ be an integer.



The dynamic programming solution involves subproblems of the following form:


What's the maximum achievable value for the sum of $z$-fields, when restricted to choosing exactly $i$ of the first $j$ items, such that the sum of the $w$-fields is at least $\alpha$, the sum of the $x$-fields is at least $\beta$, and the sum of the $y$-fields is at least $\gamma$.


You get a subproblem for each combination of values for $i,j,\alpha,\beta,\gamma$.  That's a lot of subproblems, so the dynamic programming algorithm will probably be very slow.