You are given a basket that can carry a maximum weight of weight where each element represents the weight of an apple.
Return the maximum number of apples you can place into the basket such that their total weight does not exceed
Constraints:
weight.length
weight[i]
You are given a basket that can carry a maximum weight of weight where each element represents the weight of an apple.
Return the maximum number of apples you can place into the basket such that their total weight does not exceed
Constraints:
weight.length
weight[i]