There are 5 red pens, 3 blue pens and 2 green pens in a box. Gary takes at random a pen from the box and gives the pen to his friend. He then takes at random another pen the box. What's the probability that both pens are the same colour?

To find the probability that both pens are the same color, we need to consider the different possible scenarios.

Scenario 1: Gary first takes a red pen and then another red pen.
The probability of the first event is 5/10 (5 red pens out of 10 total pens).
After the first event, there are 4 red pens and a total of 9 pens remaining, so the probability of the second event is 4/9.
Therefore, the probability of this scenario is (5/10) * (4/9) = 20/90.

Scenario 2: Gary first takes a blue pen and then another blue pen.
The probability of the first event is 3/10 (3 blue pens out of 10 total pens).
After the first event, there are 2 blue pens and a total of 9 pens remaining, so the probability of the second event is 2/9.
Therefore, the probability of this scenario is (3/10) * (2/9) = 6/90.

Scenario 3: Gary first takes a green pen and then another green pen.
The probability of the first event is 2/10 (2 green pens out of 10 total pens).
After the first event, there is 1 green pen and a total of 9 pens remaining, so the probability of the second event is 1/9.
Therefore, the probability of this scenario is (2/10) * (1/9) = 2/90.

Adding up the probabilities of the three scenarios, we get: (20/90) + (6/90) + (2/90) = 28/90.

Therefore, the probability that both pens are the same color is 28/90, which simplifies to 14/45.

To find the probability that both pens are the same color, we need to consider the different scenarios.

Step 1: Calculate the total number of ways Gary can choose two pens from the box.
There are a total of 10 pens in the box (5 red + 3 blue + 2 green). So, Gary has a choice of 10 pens for the first pick and 9 pens for the second pick.

Total ways = 10 * 9 = 90

Step 2: Calculate the number of ways Gary can choose two pens of the same color.
a) If Gary chooses two red pens, there are 5 red pens in the box, so he has a choice of 5 for the first pick and 4 for the second pick.
b) If Gary chooses two blue pens, there are 3 blue pens in the box, so he has a choice of 3 for the first pick and 2 for the second pick.
c) If Gary chooses two green pens, there are 2 green pens in the box, so he has a choice of 2 for the first pick and 1 for the second pick.

Number of ways = (5 * 4) + (3 * 2) + (2 * 1)
Number of ways = 20 + 6 + 2
Number of ways = 28

Step 3: Calculate the probability.
Probability = (Number of ways of getting pens of the same color) / (Total number of ways of choosing two pens)
Probability = 28 / 90
Probability ≈ 0.3111 or approximately 31.11%

Therefore, the probability that both pens chosen by Gary are the same color is approximately 31.11%.

To find the probability that both pens are the same color, we need to determine the total number of possible outcomes and the number of favorable outcomes.

First, let's calculate the total number of possible outcomes. In the first draw, Gary can choose any of the 10 pens in the box. After giving the pen to his friend, there are 9 pens left in the box for the second draw. Hence, the total number of possible outcomes is 10 * 9 = 90.

Now, let's calculate the number of favorable outcomes, i.e., the number of ways Gary can choose two pens of the same color. Since there are 3 different colors of pens, Gary can choose two pens of the same color in three ways: two red pens, two blue pens, or two green pens.

For two red pens: Gary can choose one of the 5 red pens in the first draw and then one of the 4 remaining red pens in the second draw. This gives us 5 * 4 = 20 favorable outcomes.
Similarly, for two blue pens, we have 3 * 2 = 6 favorable outcomes.
And for two green pens, there are 2 * 1 = 2 favorable outcomes.

Therefore, the total number of favorable outcomes is 20 + 6 + 2 = 28.

Finally, the probability that both pens are the same color is given by the ratio of the number of favorable outcomes to the total number of possible outcomes:
Probability = Favorable outcomes / Total outcomes
Probability = 28 / 90
Probability ≈ 0.3111 (rounded to four decimal places)

Hence, the probability that both pens are the same color is approximately 0.3111 or 31.11%.