humorously stated theorem that a monkey hitting keys at random on a typewriter keyboard for an infinite amount of time will surely type a given text, such as the complete works of William Shakespeare.
While a monkey is used as a mechanism for the thought experiment, it would be unlikely to ever write Hamlet.
The infinite monkey theorem states that a monkey hitting keys independently and at random on a typewriter keyboard for an infinite amount of time will almost surely type any given text, including the complete works of William Shakespeare. More precisely, under the assumption of independence and randomness of each keystroke, the monkey would almost surely type every possible finite text an infinite number of times. The theorem can be generalized to state that any infinite sequence of independent events whose probabilities are uniformly bounded below by a positive number will almost surely have infinitely many occurrences.
Discovered by embedding cosine similarity (sentence-transformers MiniLM, 384-dim).