1 // Written by Babele Dunnit <babele.dunnit@gmail.com>
2 // Found at http://www.digitalmars.com/webnews/newsgroups.php?art_group=digitalmars.D&article_id=54084
3 // Sightly modified by Leandro Lucarella <llucax@gmail.com>
4 // (some readability improvements and output removed)
12 Individual[20] children;
20 foreach(inout individual; individuals)
22 individual = new Individual;
26 Individual[N1] individuals;
31 int main(char[][] args)
34 Population testPop1 = new Population;
35 Population testPop2 = new Population;
39 for(int i = 0; i < IT; i++)
45 indi[] = testPop1.individuals ~ testPop2.individuals;
48 version (everythingOk){
49 indi[0..N1] = testPop1.individuals;
50 indi[N1..N2] = testPop2.individuals;