Genetic programming is a model of programming which uses the ideas (and some of the terminology) of biological evolution to handle a complex problem. Of a number of possible programs (usually small program functions within a larger application), the most effective programs survive and compete or cross-breed with other programs to continually approach closer to the needed solution. Genetic programming is an approach that seems most appropriate with problems in which there are a large number of fluctuating variables such as those related to artificial intelligence . The genetic programming model is mostly used with the LISP and Scheme programming languages. However, it can also be used with C and other programming languages.
Genetic programming can be viewed as an extension of the genetic algorithm , a model for testing and selecting the best choice among a set of results, each represented by a string . Genetic programming goes a step farther and makes the program or "function" the unit that is tested. Two approaches are used to select the successful program - cross-breeding and the tournament or competition approach. A difficult part of using genetic programming is determining the fitness function , the degree to which a program is helping to arrive at the desired goal. A simple example of a task suited for genetic programming would be devising a program to fire a gun. The distance by which the bullet misses its target would determine the fitness function.
Genetic programming is a challenging new approach that requires a considerable learning investment for the programmer.