whats the probability of gatting a matching pair of socks if there are 8 gree and 10 blue

I assume you mean that only two socks are going to be drawn?

p = 8/18*10/17 + 10/18*8/17 = 80/153 = 0.523

That is, it's the chance of getting a green, then a blue plus the chance of getting a blue, then a green

To calculate the probability of getting a matching pair of socks, we need to determine the total number of possible pairs and the number of pairs that have matching colors.

1. First, let's find the total number of pairs of socks. Since we have 8 green socks and 10 blue socks, we need to calculate the number of ways to choose 2 socks from a total of 18 socks:

nCr(18, 2) = 18! / (2! * (18 - 2)!) = 153

There are 153 possible pairs of socks.

2. Next, let's find the number of pairs that have matching colors. We can calculate the number of ways to choose 2 green socks and the number of ways to choose 2 blue socks:

nCr(8, 2) = 8! / (2! * (8 - 2)!) = 28
nCr(10, 2) = 10! / (2! * (10 - 2)!) = 45

There are 28 pairs of green socks and 45 pairs of blue socks.

3. Finally, to find the probability of getting a matching pair of socks, we divide the number of pairs with matching colors by the total number of possible pairs:

P(matching pair) = (28 + 45) / 153
= 73 / 153
≈ 0.477

Therefore, the probability of getting a matching pair of socks is approximately 0.477 or 47.7%.