That's more or less the same question I asked myself back during Sophmore year in High School, when I was taking my bio class. I wandered into the field of genetic programming; and being a Perl nut even at that tender young age, I wrote myself a Perl library to do it (the first GP library written in Perl, so far as I know) The end result can be found at Perls of evolution. Genetic programming or breeding perls also addresses a similar topic; though not GP according to the canonical sense, there is no way to deny that one is genetically evolving programs. Check both of 'em out.
ObLink to the papers I wrote. Feel free to drop me a line if you're curious and/or want to know more. I found Koza's book to be rather useful, myself.
perl -pe '"I lo*`+$^X$\"$]!$/"=~m%(.*)%s;$_=$1;y^`+*^e v^#$&V"+@( NO CARRIER'