Consider the following setup. A population of 500 individuals, each with a chromosome of randomly generated printable characters, is subjected to (1) random selective breeding (chromosome crossover), (2) survival of the fittest, and (3) adaptation by learning, while freely evolve in a simulated environment. At each generation, the fitness of an individual is evaluated as the distance between its chromosome and a target string:
"The very essence of instinct is that it's followed independently of reason."
The adaptation stage uses a simple hill-climbing algorithm to advance each character of the chromosome. This simulation is performed for 100 generations. At the end of each generation, the fitness score and chromosome of the highest ranked individual (the fittest) are displayed.
Click this link to watch this evolution in action (click the play button at the bottom right to enter runtime mode):