# Another political discussion

1. Jul 22, 2008

### humanino

Ivanhoe and Isaac became pirates a long time ago. Both of them run for the position of captain. Everybody slips his envelop in the box one after the other. Ivanhoe receives P votes, and Isaac receives Q votes. Assuming P>Q, what is the probability for Ivanhoe to lead during the entire voting process ?

If for instance the P votes for him have all been slipped first, he was clearly ahead the whole time. If the very first pirate voted for Isaac, then Ivanhoe was not ahead at this point.

2. Jul 22, 2008

### Jimmy Snyder

Partial results.
If q = 0, then the probability is 1
If q = 1, then the probability is (p - 1) / (p + 1) because Ivanhoe must receive the first two votes, and after that it doesn't matter when the 1 vote for Isaac occurs. The probability of Ivanhoe receiving the first two votes is:
(p / p + q) (p - 1)/(p + q - 1)
and since q = 1, this is
(p - 1) / (p + 1)

3. Jul 23, 2008

### humanino

Hi,

your partial results are not only correct, but also very close to the general form of the solution

4. Jul 24, 2008

### humanino

I don't know if anybody is interested in the solution. I did it the hard way, and once I had found the solution I realized there must be a simpler explanation. After browsing the web I finally found that indeed the problem is well known as the "Ballot problem" and even has generalized versions. There is a geometrical proof, direct solution using so-called "Andre's reflection principle", and more.

This is not a spoiler, this is more than a spoiler. The following link contains it, pretty much all :
The Ballot Problem