**Here is the question:**

There are *x* green apples and *y* red apples in a box with

and

When two apples are drawn at random, the probability that the two apples are of the same color is exactly one-half. Please find the largest possible value of *x*.

**Solution:**

First of all, the probability of the getting same color is one-half.

then do some algebraic manipulation, like cross multiplying and stuffs like that.

we are good at this point, because we have found a relationship between and ,

since x is greater than y so is positive and we can take the square root of the inequality below, and since x and y are integers we will take the integer part of the square root of 2008.

and since

then we have

Now here comes the tricky part where most students can’t get to, let’s look at what the problem asks us to find. It says find the largest possible value of x. So we want to have this,

in order to have this, we need to play around with the “x” and try to rewrite it in terms of something we have in hand. So what do we have? We have these two inequalities

So let me play around with my “x”, I love this part coz this is the technique I personally gave it a name “make something out of nothing method” 🙂

Therefore there are at most 990 green apples in the box 🙂