The Evolutionary Algorithm
Start with something that works pretty well.
Make somewhat tweaked copies of it.
Various copies compete against each other, and environment. ‘Fittest’ reproduce most.
Repeat on large populations for billions of years.
Spice things up with frequent climate changes and occasional mass extinctions.