Computer Science, asked by rajeevshreyas6145, 4 months ago

There are 22 towels in a drawer; 5 pairs of red towels, 4 pairs of yellow, and 2 pairs of green. You select the gloves in the dark and can check them only after a selection has been made. What is the smallest number of gloves you need to select to have at least one matching pair in the best case? in the worst case?

Answers

Answered by TheBrainliestKing
0

Answer:

Explanation: Answer:

Best-case = 2 gloves

Worst-case = 12 gloves

Explanation:

For the best-case: Because there is a chance that you take two gloves of the same color in the first two round the answer is two.

For the worst-case: The worst case would be if, for each color-group of gloves you take the right or left glove, for example, you take 5 left-hand red gloves then 4 left-hand yellow gloves, then 2 left-hand green gloves, because you have already taken all of the left gloves the next one is going to be a right glove that is going to pair with one of the already selected gloves, therefore, the answer is 12 -> 5+4+2+1 = 12

Similar questions