This cool puzzle (and solution) comes from my friend Mike.

Alice secretly picks two different real numbers by an unknown process and puts them in two (abstract) envelopes. Bob chooses one of the two envelopes randomly (with a fair coin toss), and shows you the number in that envelope. You must now guess whether the number in the other, closed envelope is larger or smaller than the one you’ve seen.

Is there a strategy which gives you a better than 50% chance of guessing correctly, no matter what procedure Alice used to pick her numbers?

I initially thought there wasn’t, or that the problem was paradoxically defined, but it turns out that it’s perfectly valid and the answer is “Yes.” See my first comment for an example of one such winning strategy.

*This puzzle is similar to, but not the same as, the **two envelopes paradox**. For more time-devouring reading, see Wikipedia’s **List of Paradoxes**.*

html screwed up my comment….

here’s the screwed up part:

“I know this is counterintuitive but therer are as many real number x so that x (is-smaller than) G as there are numbers x so that x (is-bigger-than) G”

Another thought:

Call the known number be “x” and the unknown number “y”.

Let Xo = x – x and Yo = y – x. Why nought? Yes.

The puzzle then reduces to guessing whether Yo > 0 or Yo 0 (or x<0) grows, the point "t" moves along the circle on the right side (or the left) towards the top, but "t" can never reach the top.

We can move the circle so the bottom point rests on the known number "x", e.g. ("x",0), and we can construct the same kind of mapping through all the (limitless) points on the number line less than "x" and through all the (limitless) points greater than "x", (limitless like Bruno described). The top point of the circle still represents Infinity because the tangent line there still does not intersect the x axis. We could do this for any "x": the top point is always fixed with respect to the circle and the circle itself is infinitely 'stretchy' as we slide the bottom back and forth along the x axis.

@Bruno: I sympathize! The text between “less than” and “greater than” symbols was lost. Repeated with text substitution to those symbols.

Another thought:

Call the known number be “x” and the unknown number “y”.

Let Xo = x – x and Yo = y – x. Why nought? Yes.

The puzzle then reduces to guessing whether Yo “is greater than” 0 or Yo “is less than” 0, both of which have equal probability.

I think the problem is that “infinity” is not a number [http://en.wikipedia.org/wiki/Infinity].

My favorite representation of infinity: (sort of like Saunders Mac Lane’s “Mathematics Form & Function”, p. 116)

Draw the real number line as an x axis.

Draw a vertical positive axis and call it the z axis (because we already used “y”).

Draw a circle centered at (x=0, z=0.5) that passes through (x=0,z=0) on the bottom and (x=0,z=1) on the top.

For every point x on the real (x) axis, there is a unique tangent line (at point “t” on the circle) that passes through the point x. The top point of the circle where the tangent line does correspond to any point x because the tangent there is parallel to and cannot intersect the x axis. The top point (0,1) represents Infinity–both negative and positive. As the magnitude of x”greater than”0 (or x”less than”0) grows, the point “t” moves along the circle on the right side (or the left) towards the top, but “t” can never reach the top.

We can move the circle so the bottom point rests on the known number “x”, e.g. (“x”,0), and we can construct the same kind of mapping through all the (limitless) points on the number line less than “x” and through all the (limitless) points greater than “x”, (limitless like Bruno described). The top point of the circle still represents Infinity because the tangent line there still does not intersect the x axis. We could do this for any “x”: the top point is always fixed with respect to the circle and the circle itself is infinitely ‘stretchy’ as we slide the bottom back and forth along the x axis.

Hmm. So what about your probability function?

lim[P(x), x “goes to” -Infinity) = 0, and

lim[P(x), x “goes to” +Infinity) = 1

still make sense, but if the odds are always even (which sounds contradictory!),

P(x) = 0.5 otherwise.

The probability function would have to be discontinuous at -/+ Infinity?

nello nersende woolkendin

@xkcd:

You “original post” is now at the end of 5+ Older Post pages.

I gave up and hacked the URL.

Maybe there could be a way of skipping to the beginning or the end?

Well, I like puzzled, but this one seems to be a little bit off with really big logical flaws in the solution. I also belive the answer should be “NO”…

Well, real includes negative numbers, and since there are the same amount of infinite numbers on each side with a median at 0, just guess larger if it’s a negative number and smaller if it’s a positive number.

@xkcd:

You “original post” is now at the end of 5+ Older Post pages.

I gave up and hacked the URL.

Maybe there could be a way of skipping to the beginning or the end?

In retrospect, this discussion could provide some interesting sociological data. What tricks do people use to assert themselves into places where they are clearly out of their depth?

What means do they use to try to appear intelligent, to “chime in” on a topic, be part of the crowd, “in the know”, even when they’re not?

In this particular tread, I observed these trends:

1) The “logistic function doesn’t matter, you can pick any increasing yadda yadda” crowd. Ie., why not just copy-paste from a previous poster? A safe and tried method, as old as mankind.

2) The “real numbers are defined as yadda yadda” crowd. Here, a single misguided post about some guy’s difficulties with real numbers provides the much needed relief for many people. “I feel uneasy about the original problem, but finally, here is someone even dumber, now I can act smart and explain!”

3) “Out-of-the-box” wannabes. Just ask Alice! Torture Bob! Man in the middle! While sometimes genuinely funny, these posts were never really insightful, and most were poorly masking the fact that not even the formulation of the problem was understood.

Pingback: Wordpress Themes

Pingback: When Intuition is Wrong and Math is Right « william chen

@xkcd, bad answer. Naughty. Go to your room.

Your extravagant formula basically says that if X is greater than zero, the answer is ‘Y is smaller’ and vice versa. Rule 1 of mathematics, KISS.

A more interesting question along the same lines is ‘what would be the answer if X and Y were permitted to be equal’?

if its a +ve number then less. if its a -ve number then more. unsure abt 0.

@Mixter:

Nope, it doesn’t. Check again and read up on some comments.

I don’t really know more than school math and applied statistics for psychologists, but from what I know about real numbers and from what my intuition tells me you wouldn’t really get far if you don’t know Alice’s strategy. From a psychological point of view (and from the suggested solutions I’ve read), you would guess ‘lower’ if the number you see is rather high and vice versa. But if I were Alice I would always choose two numbers that are very close to each other, to prevent this, maybe with a randomly or pseudo-randomly changing number of decimals.

But that’s assuming that Alice wants to “win”.

I guess if not and/or with a bit of Bayesian statistics (which I don’t quite know because our prof thinks it is nonsense) and a lot of chuzpe, you could say there’s a possibility that Alice just uses any random strategy.

Then maybe (and this is the part I’m not sure about), you could state that any possible random choosing strategy has another one with a “complementary” density function (so that the points that are above or below what a uniform distribution would look like ‘cancel each other out’ if you ‘calculate the mean of both functions’ (phew, I don’t know any math vocabulary -neither in English nor in any other language)) and then you assume equal probability for all these choosing strategies. If you ‘calculate the mean of all density functions’ you should end up with a uniform distribution density. And then, I guess, some form of ‘if the number is high, say lower’ should change the probability away from .5. (it should, with this new function, be possible to split in the middle, which would be 0.) But infinity is a bitch, so I’m not quite sure if this works. (I imagine if you take an infinite number of random choosing strategies, you could probably end with any form of ‘generalized’ or ‘mean’ distribution and that the ‘they cancel each other out’-trick does only look like it works.)

And anyway, if A acts like I stated above, this would simply not work, anyway. Only if you assign probabilities to her possible intentions and strategies.

But maybe one could win via time travel.

Nice post about the topic Math Puzzle. I enjoy this post gorgeously with all of my friends. Really nice thanks.

Good information here. I really enjoyed to play this puzzle game.

study

Pingback: Envelope Paradox? | mudkipz!

Pingback: 数学谜题：信封里的数字 | γ自由度べ

Of course rituals, there’s always the person who feels smarter than the others because he didn’t participate in such shallow ways c:

Statistics…probability…the assumption in the premise is static.

The best strategy is based upon experience with the human offering the question and a recognition of his/her social cues…

I know you were looking for math…but there ya go…;)

But if the one you read is zero, what do you do?

Thanks for the great feature and we’re very excited about having you blog for us!

I agree with an earlier post. If the number is negative, guess that the second number is greater. There are more numbers between a negative number and +infinity than there are between a negative number and negative infinity. Even though the difference is negligible in the long run, it still exists. If the first number is positive, assume the second number is lesser. If the first number is 0, guess that the second number is +Pi. Because Alice is a nerd. And nerds, on average, have a higher probability of selecting +Pi when given the chance to pick any real number.

This really just depends on the definition of random. If every number up to infinity and down to negative infinity has an equal chance of being chosen, then it hits an even 50% because the two numbers are independent variables. But if you count random as a person’s best attempt at random, then this works.

No link to \the first comment\? The default top obviously isn’t it because it references things not above.

FAIL

I was very pleased to find this site. I wanted to thank you for this great read!! I definitely enjoying every little bit of it and I have you bookmarked to check out new stuff you post.

Take a random real number between -\frac{\pi}{2} and \frac{\pi}{2} (use any continuous bounded distribution). Then take its tangent. Voilà!

@xkcd

To generalize your answer, so long as the probability of you guessing “the second number will be lower” increases as the value of the higher number increases, your strategy is a winning one.

A simple answer (which some people have given) is to say “the second number will be lower” if the first number is positive and “the second number will be higher” if the first number is negative. If both numbers Alice picks are positive, you will be right 50% of the time; likewise if both are negative. You will be right 100% of the time that Alice’s numbers straddle zero, so overall you have greater than 50% chance of being correct.

The apparent problem with this answer is that it misses one point: “no matter what procedure Alice used to pick her numbers”. If Alice’s procedure excludes either positive or negative numbers, you only have exactly a 50% chance of being correct. You can get around this as follows:

1) Pick a random real number yourself

2) Use this as the cutoff point (i.e. base your guess on whether Alice’s first number is higher or lower than your randomly generated number)

Since there is always a chance your random number will fall between Alice’s numbers, no matter what her strategy is, there is always a chance you will have a better than 50% guess rate, and you can never be worse than 50%. So, prior to choosing your cutoff point, you have a greater than 50% chance of being correct.

Really though, I think choosing zero (or any other arbitrary value) as the cutoff value is just as good an answer. Since you do not know what Alice’s procedure is, the fact that it may exclude all numbers either above or below your chosen cutoff point, is, philosophically, a moot point. It’s a “what if” that just isn’t valid. To me, the conversation goes as follows:

A: “So you’ve chosen zero as a cutoff point… but what if Alice’s number choosing procedure excludes negative numbers?”

B: “Then I can expect to be right exactly 50% of the time and no more. Why, does Alice’s procedure exclude negative numbers?”

A: “We don’t know.”

B: “So I’ll be right more than 50% of the time then.”

*Slight pause for thought, and a lingering silence*

I suppose the *best* answer in the real world would be “compile a huge dataset of which numbers people choose when asked to choose two random real numbers, benchmark Alice against people similar to her, and predict her choices based on this”. If you are happy to accept that the exact procedure Alice happens to choose is a moot point, then all you do is choose the median of Alice’s expected values, see whether the first number is higher or lower, and guess accordingly. If you want to get picky about the fact that Alice’s exact procedure may exclude numbers above or below your calculated median of her guessing range, then chuck in some probability function such that, graphically:

x axis = value of Alice’s first number

y axis = probability you’ll guess that second number will be smaller

probability function: must always have positive gradient

And you’d still want to chuck in a massive vertical discontinuity right on your calculated median of her guessing range.

For starters i would ask Alice. When she tells me it is not a negative number, and that the second number is higher than the one shown to me then i’ve successfully extinguished any gamble on chance, making the final decision 100% accurate, unless she was a liar.

Or i would simply state that i am not going to guess lower, causing my chance for choosing a higher number to be 100%, unless i was lying.

Cool simple math game:

http://myframeshoppe.ca/math/

I hate you, xkcd. And I call shenanigans. This whole thing seems like garbage to me. My wine-addled brain still has common sense and a good deal of intelligence (as well as saucy good looks!) and this whole thing just smells of troll baiting.

Good day to you, sir!

A thinking algorithm that might help you get the solution for this and many related problems:

http://jolderer.blogspot.com/2010/10/solution-algorithm-for-xkcd-math-puzzle.html

I have no idea whether this has been already posted among the 300 comments here.

I steal the envelope and sell its contents to the next person in line for half the winnings.

Pingback: Facticity » Blog Archive » Cool Math Problem I Found on XKCD Blog

A process (as a matter of fact) must have been adopted by Alice to choose two real numbers.

It is not posible (there is not sufficient computational power in the universe) to devise a process (even ‘thinking up numbers in your head’) to choose such numbers which includes all real numbers. Any such process must be a choice from a finite set of real numbers.

Each number in the set of ‘numbers involved in Alice’s process’ has, from our perspective of nil knowledge, a probability of (1/2 infinity)-1 of being negative, a probability of (1/2 infinity)-1 of being positive and 1/infinity of being 0.

From the information available to us therefore, the set could be assumed to be equivalent to the following set:

-2 -1 0 1 2

for which the answer to ‘which is likely to be higher if you are given one example’ is trivial (unless the number you are given is 0). But the chances of the number being 0 is only 1/infinity or, effectively, nil.

I think my riddle solving brain tried to hack this one. My answer was “Yes, the number will be larger or smaller than the one I saw.” That’s cheating, right?

I bet if I really tried I could come up with something similarly clever to the other comments, but I’m just going to have to go with “ask Alice ‘is your other number smaller or larger?’”

If the number you are shown is positive then guess lower.

If the number you are shown is negitive then guess higher.

Right or wrong?

Thank you very much for this very interesting riddle! I would like to try and give a strict mathematical proof for the correctness of the strategy, given that the numbers are not identical. The proof uses a Latex-like syntax: R are the real numbers, \int_R is an integral over R, 1_{x<y} is the indicator function of {x<y}.

Alice secretly picks two random numbers. No matter which strategy she uses, this amounts to fixing a bivariate distribution on R^2. (This also includes deterministic strategies.) Let X and Y be the two random variables describing the numbers picked by Alice. Denote the corresponding joint probability measure on R^2 by P_{XY}. Since the numbers should be different for the strategy to work, we will assume

P_{XY}(X=Y) = 0.

Let further Z be the result of the coin flip. If Z=0, X is shown to Bob, if Z=1, Y is shown to Bob. Finally, let W be the random variable according to the given strategy, which Bob uses to make his decision. If W=0, Bob says "the other number is lower", if W=1, Bob says "the other number is higher".

We define the following events:

H := "The other number is indeed higher",

L := "The other number is indeed lower".

We first compute the conditional probability of W=0 given that the other number is indeed lower (so Bob guesses correctly in this case):

P(W=0 | L) = [P(W=0 and XY and Z=X)]

/ [P(XY and Z=X)].

Since Z is independent of X and Y, the denominator is equal to 0.5. We thus have

P(W=0 | L) = 2 [P(W=0 and XY and Z=X)].

Writing the probabilities as integrals of the joint probability measure, we find

P(W=0 and X<Y and Z=Y)

= \int_0^1 \int_R \int_R 1_{w < 1/(1+exp(-y))} 1_{x < y} 0.5 dP_{XY}(x,y) dw

= 0.5 \int_R \int_R 1/(1+exp(-y)) 1_{xY and Z=X), and we obtain

P(W=0 | L) = \int_R \int_R 1/(1+exp(-y)) 1_{xy} dP_{XY}(x,y).

Exactly the same reasoning shows

P(W=1 | H) = \int_R \int_R [1- 1/(1+exp(-x))] 1_{xy} dP_{XY}(x,y).

Due to the coin flip, we obviously have

P(H) = P(L) = 0.5.

We are now ready to compute the probability of Bob guessing correctly:

P(“Bob guesses correctly”)

= P(W=0 and L) + P(W=1 and H)

= P(W=0 | L) P(L) + P(W=1 | H) P(H)

= 0.5 [ \int_R \int_R 1/(1+exp(-y)) 1_{xy} dP_{XY}(x,y)

+ \int_R \int_R [1- 1/(1+exp(-x))] 1_{xy} dP_{XY}(x,y) ]

= 0.5 \int_R \int_R 1_{xy} [1 + 1/(1+exp(-x))

- 1/(1+exp(-y)) ] dP_{XY}.

Note that if x<y, we have 1/(1+exp(-x)) 0.5 * 1 + 0.5 * 1 = 0.5.

Obviously, the proof also works for every other strictly monotonic increasing function mapping R to [0,1].

For some reason, some of the greater than and less than signs in my previous post were not printed. Moreover, parts of the comment were just omitted, probably due to the braces and special characters. Sorry.

Second try:

Alice secretly picks two random numbers. No matter which strategy she uses, this amounts to fixing a bivariate distribution on R^2. (This also includes deterministic strategies.) Let X and Y be the two random variables describing the numbers picked by Alice. Denote the corresponding joint probability measure on R^2 by P_{XY}. Since the numbers should be different for the strategy to work, we will assume

P_{XY}(X=Y) = 0.

Let further Z be the result of the coin flip. If Z=0, X is shown to Bob, if Z=1, Y is shown to Bob. Finally, let W be the random variable according to the given strategy, which Bob uses to make his decision. If W=0, Bob says “the other number is lower”, if W=1, Bob says “the other number is higher”.

We define the following events:

H := “The other number is indeed higher”,

L := “The other number is indeed lower”.

We first compute the conditional probability of W=0 given that the other number is indeed lower (so Bob guesses correctly in this case):

P(W=0 | L) = [P(W=0 and X less Y and Z=Y) + P(W=0 and X larger Y and Z=X)] / [P(X less Y and Z=X)].

Since Z is independent of X and Y, the denominator is equal to 0.5. We thus have

P(W=0 | L) = 2 [P(W=0 and X less Y and Z=Y) + P(W=0 and X larger Y and Z=X)].

Writing the probabilities as integrals of the joint probability measure, we find

P(W=0 and X less Y and Z=Y)

= \int_0^1 \int_R \int_R 1_{w less 1/(1+exp(-y))} 1_{x less y} 0.5 dP_{XY}(x,y) dw

= 0.5 \int_R \int_R 1/(1+exp(-y)) 1_{x less y) dP_{XY}(x,y).

A similar computation works for P(W=0 and X larger Y and Z=X) and we obtain

P(W=0 | L) = \int_R \int_R 1/(1+exp(-y)) 1_{x less y} dP_{XY}(x,y)

+\int_R \int_R 1/(1+exp(-x)) 1_{x larger y} dP_{XY}(x,y)

Exactly the same reasoning shows

P(W=1 | H) = \int_R \int_R [1- 1/(1+exp(-x))] 1_{x less y} dP_{XY}(x,y)

+ \int_R \int_R [1- 1/(1+exp(-y))] 1_{x larger y} dP_{XY}(x,y).

Due to the coin flip, we obviously have

P(H) = P(L) = 0.5.

We are now ready to compute the probability of Bob guessing correctly:

P(“Bob guesses correctly”)

= P(W=0 and L) + P(W=1 and H)

= P(W=0 | L) P(L) + P(W=1 | H) P(H)

= 0.5 [ \int_R \int_R 1/(1+exp(-y)) 1_{x less y} dP_{XY}(x,y)

+ \int_R \int_R 1/(1+exp(-x)) 1_{x larger y} dP_{XY}(x,y)

+ \int_R \int_R [1- 1/(1+exp(-x))] 1_{x less y} dP_{XY}(x,y)

+ \int_R \int_R [1- 1/(1+exp(-y))] 1_{x larger y} dP_{XY}(x,y)]

= 0.5 \int_R \int_R 1_{x less y} [1 + 1/(1+exp(-x))

- 1/(1+exp(-y)) ] dP_{XY}

+ 0.5 \int_R \int_R 1_{x larger y} [1 + 1/(1+exp(-y))

- 1/(1+exp(-x)) ] dP_{XY}.

Note that if x less y, we have 1/(1+exp(-x)) less 1/(1+exp(-y)). Thus, both integrands above are strictly larger than 1. Since

\int_R \int_R 1 dP_{XY}(x,y) = 1

due to the properties of the probability measure, we obtain

P(“Bob guesses correctly”) < 0.5 * 1 + 0.5 * 1 = 0.5.

Obviously, the proof also works for every other strictly monotonic increasing function mapping R to [0,1].

Wait…couldn’t this be seen in an overly simplistic way?

My mathematician/physicist friend gets onto me for overly simplifying some things (math stuff) and for over complicating things (everything else), but my simplistic approach also showed him that the piecewise f(x) = 0 for all rational x and f(x) = x for all irrationals (or was that the other way around?) was actually discontinuous. :p

Anyway, so simplistic:

Number line!

While real numbers are considered infiniate, my non-math (read: I hate Proofs! :p) brain likes putting 0 at the center point. That is, 0 is exactly \half-way\ between negative infinity and positive infinity.

Considering this, if the first number you see, let’s call it, oh, \x\, is greater than 0, you know there is a greater chance, no matter how slight, that the other number, let’s call it…\goo-goo\, is going to be less than x.

The reason for this is that it has 50% of the real numbers (that is, negative infinity to zero), PLUS whatever numbers are between 0 and x, as available results for goo-goo. However, it only has 50% of the reals (from 0 to infinity) MINUS the absolute value of x – 0…er, the…value of…whatever! So LESS than 50% are larger than x. :p

Now, my math friend would probably tell me that this is a stupid way of thinking because infinity goes infinitely in both directions. In this way, picking a point gives you a 50/50 on either side regardless of the point picked.

…but maybe not. Guess I’ll have to ask him.

…also, having now read the way you did this in your first post, mine seems similar, while completely dumbed down. ^_^

Oh, to clarify:

IF x > 0, goo-goo is more probably < x

IF x x

Note the singularity:

IF x = 0, goo-goo is greater than OR less than x with equal probability

Now, if we try to add in behavioral traits, this changes. For example, in my experience, people TEND to be more likely to pick positive numbers than negative ones (though some fields, such as mathematics, make exception of this.)

So, were I given x of 0, I would probably say that goo-goo is going to be > x=0.

Oh yeah, physics, then I decided to turn from that path. Now they’re giving me a degree or two in economics and I don’t know what to do with myself. Maybe I should have gone with math in the first place.

…but dangit! I HATE proofs! Obvious things sometimes ARE obvious!

Pingback: Bucles

Notebook servisi istanbul

Let’s see if we can bring this all together…

1. “if -ve choose “bigger”, if +ve, choose “smaller”

Let’s call this “right for the wrong reasons”. Well, first of all, it is not right, but it is a start. More importantly, there is a flaw in the reasoning. Sure there are as many -ve numbers as +ve, but there are also as many numbers less than 100 as there are greater than 100. There are also just as many numbers between 0 and 1 as there are greater than 0. Infinity is strange that way (in fact this strict-subset-is-as-big-as-the-whole is an equivalent definition of infinity).

2. So 0 isn’t special. We can take care of that. Just pick a “random” number as our “pivot”, not zero. This, in a complicated way, is what the solution does, via the logistic function and a number between 0 and 1, etc. But the choice of pivot doesn’t matter, as long as we don’t limit ourselves to what pivot could be chosen. And this is important – that way, regardless of Alice’s algorithm, we will at least *sometimes* pick a good pivot. And if we pick a bad pivot, our odds are still 50/50.

So step 2 is just an refinement of the somewhat naive step 1. Now, how are we doing?

3. As mentioned in some comments, if we pick a pivot ‘p’, sometimes ‘p’ will be less than both x and y (Alice’s numbers), and sometimes it will be larger than both x and y. ie sometimes it will be a bad pivot. In those cases, the odds of x being greater than y or vice versa are 50/50 as Bob fairly chose which number you saw. The interesting case is when p is between x and y. Recall, we pick “the other is bigger” if the number we see is less than p, otherwise “the other is smaller”. When p is between x and y, our algorithm picks the correct number – 100%, not 50%, of the time.

4. So, now the question/conclusion is – what are the complete odds using our algorithm? As seen in other comments, we get:

A: when p is less x and y = 50

B: when p is greater x and y = 50

C: when p is between x and y = 100

Since C *does* happen, our total odds are greater than 50%.

Tada!

?

Many people stop there, and say, even if it goes against my mathematical thinking, the answer must be “greater than 50%”.

5. The question is _how much greater_? Well, measure the 3 sections of possible p locations, labeled A,B,C above. The odds of p landing in C are

odds of C = len(C) / (len(A) + len(B))

note that len(C) is finite (ie |x-y|) whereas both A and B are infinite**. So yes, your odds are “greater than 50%”, but how much greater? – 0% greater. Not *almost* 0, but exactly 0. Infinity is big that way.

6. So are we back to 50/50? I think so, but we now get to the point where it depends how you interpret the question. Note above (in 5) that I put ** beside infinite as the lengths of A and B. Are they “really” infinite? Mathematically, yes. A is the range of all numbers less than both x and y. Infinite. But practically, they are not infinite, as Alice, a mere mortal(?), can in the end only think up – and write down – numbers that are finite. So pick imagine some finite range for Alice’s choices – to make it simple, pick 0 to 100. All her numbers will be in this range. Obviously a algorithm that picks p = 50 for a pivot will work well. But any random number between 0-100 will work as a pivot, some just better than others. This is the whole crux of our algorithm. So as long as Alice is forced into a finite range, a random pivot will have a non-zero chance of working (no more divide by infinity) and we will be better than 50%.

7. Are we done? Really close. What we can more precisely say, is that (most likely) both Alice and You are finite mortals, so you each need to pick a method of choosing a “random” number from all the reals. As mentioned elsewhere, a perfect method for choosing this doesn’t exist, so both methods will be “finite”. Thus the entire question boils down to:

does the range of your “random” selection overlap Alice’s range of “random” selection. If yes, then your odds are better than 50/50. If no, then 50/50 it is.

Do you have a better randomizer than Alice?

Well,considering that Alice proposed this mind-twisting game,I would say that she made X=Y,just to screw with us.So,it will not have any difference wich envelope you pick.’-’

I believe I can prove that the awns is no.

Let alice peek this strategy: She loves number 4.

Then no mater what your awns is the probability that you will succeed is always zero (larger or smaller)

Dear All

My apologies if this has been said before however it occurs to me the points being argued are to do with how one interprets the question. Yes it is possible by using and increasing function (such as is greater than 0 step function etc) as a conditions. Which as Mr xkcd points out can be chosen such that it is monotonically increasing, which can be used to improve the odds (though potentially EXTREMELY small), of the AVERAGED probability of guessing correctly. However picking a fixed cut off point (fixing the uniformly distributed `cut off” and interpreting this with p(x)) you have a `choice’ based on a fixed number which does not guarantee a greater than even odds of guessing correctly, and here in lies the problem.

YES, you can have a strategy that will give you greater that even odds if repeated

but as interpreted by me the answer to the original question is

NO

if Alice says `10, higher or lower ?’ there is no answer that guarantees a p>0.5 chance of being correct. This is irrefutable, Alice picks 10 and 9,11 with equal probability.

However this DOES NOT mean that the original argument is incorrect f you play as Alice vs Mr xkcd, even knowing his strategy he does have a greater than 0.5 * #rounds-played expected value of wins, for exactly the reason he explains

Q.E.D. bitches

Sorry if any of that was unclear