... implement a genetic algorithm

Refer to the documentation for the classes GeneticAlgorithm and GeneticAlgorithmIndividual. You will want to subclass each of these classes and implement custom methods defining how fitness tests are run.

See the Creatures demo for an example.