Real Numbers: A Taxi Challenge and Two Ways to Calculate a Sleep Probability

Sawyer poses a consecutive-taxi puzzle and solves a five-night dog-sitting problem with a probability table and a counting argument.

SaSawyerPonente · Jane Street
Canal
Jane Street
Publicado
6 jun 2020
Vídeo
8:03
Lectura
3 min
Diapositivas
3
Original
inglés
Abrir en YouTube
Al desplazarte, el vídeo se reduce a la esquina inferior derecha y sigue reproduciéndose. Los subtítulos siguen tu idioma de lectura.
Idioma de lecturaDisponible en 2 idiomas
Este artículo aún no está en español, así que se muestra el original en inglés.
RESUMEN

En 30 segundos

In this episode of Real Numbers, Sawyer asks for the chance that six independently selected cars contain three consecutive taxis. He leaves that challenge open and solves the previous episode’s problem: the chance of at least two undisturbed nights in five is 131/243.

  1. 1Three taxis in a rowEach of six cars is independently a taxi with probability 1/2. The challenge asks for the probability that at least three adjacent cars are taxis.
  2. 2A table of sleep outcomesColumns count nights and rows track zero, one, or at least two full nights of sleep.
  3. 3Combine disjoint pathsAfter two nights, there are two ways to get exactly one full night, each with probability 2/9.
  4. 4Count the complementSubtract the probability of zero or one undisturbed night from one to obtain 131/243.

Conclusiones

  1. Track a probability distribution over states to calculate outcomes one trial at a time.
  2. Multiply probabilities along independent paths and add mutually exclusive paths leading to the same state.
  3. The complement of at least two successes is zero or one success.
  4. The five-night sleep problem has probability 131/243, approximately 0.5391.
  5. The new challenge asks about a run of three taxis among six independent cars.
TEXTO COMPLETO

Lee el texto editado por capítulos

Solo la transcripción
01

The taxi challenge

Sawyer introduces six independent cars, each with a one-half chance of being a taxi. He asks for the chance of three consecutive taxis.

Welcome to Real Numbers, where we explore mathematics through real-world problems. This week’s challenge takes us to the traffic lights of Metropolis, where half the cars are yellow taxis.

You and a superstitious friend want a taxi that is immediately behind another taxi and immediately in front of a third. Six cars are stopped at a light, and each is independently a taxi with probability 1/2. What is the probability that at least three taxis appear consecutively?

The six-car taxi problem
DIAPOSITIVA 1 / 3The six-car taxi problemThe slide states the independent one-half probability and asks about three taxis in a row.
02

A computational solution

The previous problem asks about two full nights of sleep in five. A table updates the probabilities of zero, one, and at least two full nights.

First, let’s solve last week’s problem. While dog-sitting Fluffy for five nights, we are disturbed on each night with probability 2/3. What is the probability that we get at least two full nights of sleep? One approach tracks the probabilities one night at a time.

Draw a table whose columns represent the number of nights and whose rows represent zero, one, or at least two full nights of sleep. Each entry is the probability of reaching that state after the number of nights in its column. Since we only need at least two, we can combine all larger counts in the final row.

At zero nights, the probability of zero full nights is 1 and the other entries are 0. Each new night leaves the count unchanged with probability 2/3, or increases it with probability 1/3. Arrows between entries can show these transitions.

To follow an arrow, multiply the probability of the starting state by the transition probability. After one night the probabilities are 2/3 for zero full nights and 1/3 for one full night.

After two nights, zero full nights can occur only if we were disturbed on both nights. Independence gives (2/3) × (2/3) = 4/9.

Exactly one full night can happen in two disjoint ways: sleep the first night and be disturbed the second, or be disturbed first and sleep the second. Each has probability 2/9, so adding them gives 4/9.

Two full nights require two undisturbed nights, with probability (1/3) × (1/3) = 1/9. The column sums to 4/9 + 4/9 + 1/9 = 1, as the probabilities of all possible outcomes should.

Probability table after two nights
DIAPOSITIVA 2 / 3Probability table after two nightsThe three rows show probabilities 4/9, 4/9, and 1/9 for zero, one, and at least two full nights.

Continue updating the table through the fifth night to obtain the probability of at least two full nights. Rather than watch every calculation, let’s look at another method based on counting.

03

A combinatorial solution

Count the complementary cases of zero and one full night. Both methods yield 131/243; the taxi puzzle is left for viewers.

Combinatorics is the mathematics of counting. The complement of at least two full nights is at most one: either exactly zero or exactly one. These cases are disjoint, so subtract their combined probability from 1.

There is only one way to get zero full nights: Fluffy disturbs us all five nights. The probability is (2/3)^5 = 32/243.

Exactly one full night can occur on any of the five nights. Each arrangement has probability (2/3)^4 × (1/3), and there are five such arrangements. Therefore the probability is 5 × (2/3)^4 × (1/3) = 80/243.

Complement calculation
DIAPOSITIVA 3 / 3Complement calculationThe displayed arithmetic subtracts the probabilities of zero and one full night from one.

The desired probability is 1 − (32/243 + 80/243) = 131/243, or approximately 0.5391. The computational table produces the same result: slightly more than half the time we get at least two full nights of sleep.

Now try the new problem: six cars in a row are independently taxis with probability 1/2 each. What is the chance of three consecutive taxis? Explain your reasoning and submit your solution.

Más de este canal

1:48:29EN
JSJane Street· 16 oct 2026How AI Is Changing Programming: John Krazit and Ron MinskyRon Minsky, John Krazit · Jane StreetJane Street’s AI tooling lead and the Signals and Threads host examine agent infrastructure, security, code review and the changing experience of writing software.Agentes de programaciónDeveloper productivityEvaluaciones+2
1:36:37EN
JSJane Street· 23 sept 2026Aaron Bauer on Teaching Software Engineering in the Age of AIRon Minsky, Aaron Bauer · Jane StreetHow learning goals, active practice and editor design shape engineering education when models can generate the code.AI in EducationSoftware engineeringEducation+2
9 diapositivas1:05:45EN
JSJane Street· 11 sept 2026Cyrus Omar on Live Programming and a Computational Commons for Humans and AICyrus OmarA demonstration of Hazel shows how immediate feedback, structured collaboration and carefully scoped permissions could support people and AI agents working together.Programming LanguagesHuman-AI CollaborationFlujos de desarrollo y pruebas+2
1:25:00EN
JSJane Street· 2 sept 2026Eric Mannes on Turning Messy External Data Into Trading ResearchRon, Eric Mannes · Jane StreetFrom commodity futures and an Excel risk system to point-in-time datasets and AI, Eric Mannes explains the domain knowledge behind data engineering at Jane Street.Data quality & curationFlujos de desarrollo y pruebasInvesting+2
7 diapositivas1:16:29EN
JSJane Street· 26 ago 2026Grant Sanderson and Alok Puranik: Positional Encodings Through Group TheoryGrant Sanderson, Alok Puranik · 3Blue1BrownStarting with assumptions about attention, they derive matrix exponentials and connect rotations, decay and Jordan blocks to RoPE and ALiBi.Transformers & attentionMathematicsFundamentos de ML+1
27:39EN
JSJane Street· 21 ago 20263Blue1Brown and Jane Street on Trading, Machine Learning and CultureGrant Sanderson, Nitya, In Young, Craig, Alok · 3Blue1BrownGrant Sanderson talks with Jane Street colleagues about market making, shared compute, research and the paths that brought them to the firm.Machine LearningFintechCompany Culture+2