Have you ever sat in a doctor's office for hours despite having an appointment at a specific time, has the hotel turned down your reservation because it's full? Or have you been bumped off a flight that you paid for? These are all symptoms of overbooking, a practice where businesses and institutions sell or book more than their full capacity. While often infuriating for the customer, overbooking happens because it increases profits while also letting businesses optimize their resources. They know that not everyone will show up to their appointments, reservations and flights, so they make more available than they actually have to offer. Airlines are the classical example, partially because it happens so often, about 50000 people get bumped off their flights each year. That figure comes at little surprise to the airlines themselves, which used statistics to determine exactly how many tickets to sell. It's a delicate operation, sell too few and they're wasting seats, sell too many and they pay penalties, money, free flights, hotel stays and annoyed customers. So here's a simplified version of how their calculations work. Airlines have collected years worth of information about who does and doesn't show up for certain flights. They know, for example, that on a particular route, the probability that each individual customer will show up on time is 90 percent. For the sake of simplicity, will assume that every customer is traveling individually rather than as families or groups, then if there are 180 seats on the plane and they sell 180 tickets, the most likely result is that 162 passengers will board. But of course, you could also end up with more passengers or fewer. The probability for each value is given by what's called a binomial distribution, which peaks at the most likely outcome. Now let's look at the revenue. The airline makes money from each ticket buyer and loses money for each person who gets bumped. Let's say a ticket costs 250 dollars and isn't exchangeable for a later flight and the cost of bumping a passenger is 800 dollars. These numbers are just for the sake of example. Actual amounts vary considerably. So here, if you don't sell any extra tickets, you make 45000 dollars. If you sell 15 extras and at least 15 people are no shows, you make forty eight thousand seven hundred fifty dollars. That's the best case. In the worst case, everyone shows up, 15 unlucky passengers get bumped and the revenue will only be thirty six thousand seven hundred fifty dollars, even less than if you only sold 180 tickets in the first place. But what matters isn't just how good or bad a scenario is financially, but how likely it is to happen. So how likely is each scenario? We can find out by using the binomial distribution in this example, the probability of exactly 195 passengers boarding is almost zero percent. The probability of exactly 184 passengers boarding is one point one one percent and so on. Multiply these probabilities by the revenue for each case, add them all up and subtract the sum from the earnings by 195 sold tickets and you get the expected revenue for selling 195 tickets. By repeating this calculation for various numbers of extra tickets, the airline can find the one likely to yield the highest revenue in this example. That's 198 tickets from which the airline will probably make forty eight thousand seven hundred seventy four dollars, almost 4000 more than without overbooking. And that's just for one flight. Multiply that by a million flights per airline per year. And overbooking adds up fast. Of course, the actual calculation is much more complicated airlines apply many factors to create even more accurate models, but should they? Some argue that overbooking is unethical. You're charging two people for the same resource. Of course, if you're 100 percent sure someone won't show up, it's fine to sell their seat. But what if you're only 95 percent sure, 75 percent. Is there a number that separates being unethical from being practical?