Skip to content
This repository was archived by the owner on Nov 14, 2024. It is now read-only.

o7q/InfiniteMonkeySimulator

Repository files navigation

This repository is no longer maintained.

This was one of my C++ applications I made in order to learn C++. I never plan to update it.

Chimpanzee probably not typing Hamlet

Simulate an immortal monkey typing on a typewriter.



Overview

A super simple program I made in an hour. It allows you to simulate how many attempts it would take to get a desired string from random strings.

I made this for fun using the Mersenne Twister pseudorandom number generator: https://en.wikipedia.org/wiki/Mersenne_Twister

InfiniteMonkeySimulator is based on the Infinite Monkey Theorem: https://en.wikipedia.org/wiki/Infinite_monkey_theorem


Usage

Interface

  • Search Phrase Phrase you want to search for
  • Maximum Attempts Maximum search attempts (! for infinite, capped at the 64-bit integer limit)
  • Custom Alphabet
    • Lower Lowercase letters only
    • Upper Uppercase letters only
    • Both Lowercase and uppercase letters only
    • Num Numbers only
    • NumLower Numbers and lowercase letters only
    • NumUpper Numbers and uppercase letters only
    • NumBoth Numbers, lowercase, and uppercase letters only
    • Custom Import a custom alphabet
  • Display Output Should it output the strings (greatly slows down program, inputting 'r' will reset the program)

InfiniteMonkeySimulator
Written in C++ and compiled using MinGW G++