All tales

A story

Socks in the dark

Draft: written by an AI helper and not yet checked by a teacher.

Tap a paragraph to see it in words.

The light is out and I must dress in the dark. The drawer holds ten black socks and ten white socks, all mixed. I need two socks of the same colour; I do not mind which.

Dark. The drawer: black () and white (), . I need of the same colour.

; least to be sure of two of one colour.

How many must I take to be sure? Take one: it is black or white. Take a second: the two may differ. Take a third: it must match one of the first two, because there are only two colours and three socks. So three are enough, and two are not.

Take : any colour. : they may differ. For there are more socks than colours (), so two match (the pigeonhole principle). So is enough and is not.

.

What if I need two black socks? Now I can be unlucky for a long time: all ten white socks may come first. Only after them is every sock black, and I need two black ones: twelve socks.

For two black ones the worst case is all white first, then black: socks.

Two black: .

The surprise: with three colours of socks I would need four, and with ten colours eleven. Always one more than the number of colours.

For colours I need socks: and .

.

Letters of words: 555 → 232 → 37.

How to read the signs

  • the number of black socks
  • f takes each element of A to an element of B
  • there exist
  • is not equal to
  • so; it follows that
  • n k: the number of socks needed for k colours