}
population.sort();
}
public static void main(String[] args) {
GeneticAlgorithm genetic = new BasicGeneticAlgorithm();
initPopulation(genetic);
genetic.setMutationPercent(MUTATION_PERCENT);
genetic.setPercentToMate(PERCENT_TO_MATE);
genetic.setMatingPopulation(MATING_POPULATION_PERCENT);
genetic.setCrossover(new Splice(CUT_LENGTH));
genetic.setMutate(new MutateShuffle());
boolean done = false;
int iteration = 0;
while(!done)
{
iteration++;
genetic.iteration();
double thisSolution = genetic.getPopulation().getBest().getScore();
System.out.println(iteration + ": " + thisSolution);
}
}