You are on page 1of 13

24-4-2020 The Infinite Monkey Theorem Experiment

This is a live experiment, running since April , by Russell and Amber.

Audio is off by default.

Begin with Audio

Continue Muted

Here is a piano with just two working keys; G and E-flat. Go ahead, press them.

Enable Audio

We instructed a computer to hit a random key, four times. How many attempts were
needed to play the correct notes to the start of the iconic Beethoven’s th ? Here
was the first attempt…

Enable Audio

https://pudding.cool/2020/04/infinite/ 1/13
24-4-2020 The Infinite Monkey Theorem Experiment

Replay

Nope, not it. But after attempts, success! Here are the last few in action. Granted,
it’s not perfect, but the notes are right.

Enable Audio

https://pudding.cool/2020/04/infinite/ 2/13
24-4-2020 The Infinite Monkey Theorem Experiment

Replay

So why did we do this? Because we want to make you believe in the infinite monkey
theorem.

According to Wikipedia, “the infinite monkey theorem states that a monkey hitting
keys at random on a typewriter keyboard for an infinite amount of time will almost
surely type any given text, such as the complete works of William Shakespeare.”

https://pudding.cool/2020/04/infinite/ 3/13
24-4-2020 The Infinite Monkey Theorem Experiment

it was the best of times it was the blurst of times

“Yeah, right,” you may be thinking. You are not alone. Podcasting mogul Joe Rogan has
mostly refused to believe it (though to be fair, he did fixate more on the monkey’s
behavior than the concept).

In episode he admits, “it could be possible, but I’ve seen no evidence that it has
ever been able to be replicated, even in a simple sentence.”

Challenge accepted, Joe. Though we thought it would be more fun to do it with music
instead of something that felt like required school reading.

Before we jump back into the tunes, a quick but important math digression. How likely
is the Shakespeare thing, for real? Even if we just ask a monkey to type Hamlet,
without punctuation, the probability is unthinkably small.

(Scroll this box)

1 in 3,400,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,00
0,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000
,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,
000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,0
00,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,00
0,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000
,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,
000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,0
00,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,00
0,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000

https://pudding.cool/2020/04/infinite/ 4/13
24-4-2020 The Infinite Monkey Theorem Experiment

,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,
000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,0
00,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,00
0,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000,000

Given that there are possible options for each key press, we get ( / )x( / )x
… and so on. We have to write this out about times (the approximate length of
Hamlet).

To begin to understand where this insane number comes from, we bring back
Beethoven. How do we calculate the probability of just getting the first two notes (G, G)
correct from just two keys?

There are two possible results for just the first note:

E♭

2 possibilities = 1 / 2 = 50% chance of getting it correct.

And for two notes in a row:

G — G

G — E♭

E♭ — G

E♭ — E♭

4 possibilities = 1 / 4 = 25% chance of getting it correct.

As we play additional notes, the chances of success become more slim. Here is that
same thing, visually, with all four notes.

1 note 1 in 2

2 notes 1 in 4

https://pudding.cool/2020/04/infinite/ 5/13
24-4-2020 The Infinite Monkey Theorem Experiment

3 notes 1 in 8

4 notes 1 in 16

You get the picture. The number of possibilities goes up exponentially with each new
note, but the probability is never zero. Shakespeare will effectively take “forever,” but
if we did have forever, it would (almost surely) happen!

While the probability kept shrinking for the Beethoven melody, it was still quite likely,
quite quickly. But we cheated, a bit. We assumed that all notes are the same length.
What happens to the probability when we include two possible durations for each note?

1 note 1 in 4

2 notes 1 in 16

3 notes 1 in 64

4 notes 1 in 256

That escalated quickly! In our experiment, we ran this one as well. It took attempts
to get it right. Here are the last five attempts.

Enable Audio

https://pudding.cool/2020/04/infinite/ 6/13
24-4-2020 The Infinite Monkey Theorem Experiment

Replay

But I think Joe needs more proof. After all, we aren’t even using a full piano equivalent
of a typewriter. So we’ve actually crafted a real experiment, which has now been
running since Apr. , .

Days Hours Minutes Seconds

10 14 12 32

We ask the computer to perform up to millions of random attempts every minute to


speed up our simulation. Each time it makes a breakthrough, we gradually increase the
complexity by increasing the melody length, the note duration options, or piano size.
Here is what has been achieved so far:

https://pudding.cool/2020/04/infinite/ 7/13
24-4-2020 The Infinite Monkey Theorem Experiment
Song Symphony No. 5 I
Artist Ludwig van Beethoven
Odds 1 in 16
Attempts 12
Est. Completion Finished Apr. 13, 2020

Song Symphony No. 5 II


Artist Ludwig van Beethoven
Odds 256
Attempts 126
Est. Completion Finished Apr. 13, 2020

Song Still Dre


Artist Dr. Dre
Odds 65,536
Attempts 61,713
Est. Completion Finished Apr. 14, 2020

Song Bridal Chorus


Artist Richard Wagner
Odds 104,976
Attempts 5,653
Est. Completion Finished Apr. 14, 2020

Song Twinkle Twinkle Little Star


Artist Wolfgang Amadeus Mozart
Odds 279,936
Attempts 313,497
Est. Completion Finished Apr. 14, 2020

Song Sweet Child O' Mine


Artist Guns and Roses
Odds 1,679,616
Att t 1 443 826
Show All

And if you were hoping to catch a live performance, you’re in luck! There is a live show,
right here, / / . Currently in the works below is Another One Bites the Dust by
Queen. We slowed it down so you can keep up. Not familiar with the song? Watch it on
YouTube .

Enable Audio

https://pudding.cool/2020/04/infinite/ 8/13
24-4-2020 The Infinite Monkey Theorem Experiment

Replay Jump to Closest

rest

We think there is a good chance it will be played correctly in the next day or so.

Want to see everything in our experiment? Play around with each melody below to
generate random attempts.

Symphony No. I

Enable Audio

https://pudding.cool/2020/04/infinite/ 9/13
24-4-2020 The Infinite Monkey Theorem Experiment

Generate Play Correct

All said and done, the point here isn’t the real numbers, but the faith that given enough
time, randomness will prevail. Will our experiment eventually play even the simple
Nokia ringtone in our lifetime? Almost certainly not. Given enough time would it?
Almost surely.

A parting thought: Let’s agree that many creative pursuits can and will be able to be
replicated by chance. That is discouraging. But, perhaps it’s more important to know
that recognizing what is worthy of our time and attention is still (for now) something
that requires our critical intervention.

Thanks for reading! Want to support more of these stories? Become a friend of The Pudding
on Patreon.

Be sure to visit the inspirational Library of Babel for more infinite monkey theorem-esque content.
Want more data-driven experiments? Check out our Birthday Paradox explainer or The Gyllenhaal
Experiment.

Data for this story is updated every minutes, available here. We deviated from the typical
thought exercise implementation by restarting after each attempt instead of a continuous string of
key mashing. Estimated time to completion is based on how many attempts per minute we are

https://pudding.cool/2020/04/infinite/ 10/13
24-4-2020 The Infinite Monkey Theorem Experiment

running in our calculation, which is throttled to get a relatively consistent progression timetable
(and is capped at million per minute). Only showing the closest attempt in the most
recents attempts in the live chart.

The full proof and explanation is available on Wikipedia. Send love or hate to sup@pudding.cool.

Just How Does Kidz Bop Censor Songs?

https://pudding.cool/2020/04/infinite/ 11/13
24-4-2020 The Infinite Monkey Theorem Experiment

The Evolution of the American Census

The Emotional GIF Range of Celebs

https://pudding.cool/2020/04/infinite/ 12/13
24-4-2020 The Infinite Monkey Theorem Experiment

Where will you need your umbrella?

The Pudding is a digital publication that explains ideas debated in culture with visual essays.
The Pudding® is made in Brooklyn, NY; Seattle, WA; San Antonio, TX; and Great Barrington, MA.

FACEBOOK ABOUT

TWITTER PRIVACY

INSTAGRAM NEWSLETTER

PATREON RSS

https://pudding.cool/2020/04/infinite/ 13/13

You might also like