public void run(int nOfIterations){
		int i = 0;
		while (i < nOfIterations){
			i++;
			ArrayList <Chromosome> newPopulation;
			newPopulation = new ArrayList<Chromosome>();
			
			for (Chromosome aSubject : population){
				if (isTimeToMutate())
					aSubject.mutate();
				else
				{	
					for(Chromosome aCouple : population){

						if (isTimeToMate() && aCouple != aSubject){
							Chromosome aNewSubject = aSubject.join(aCouple);
							if (aCouple.eval() < aNewSubject.eval()
								|| aSubject.eval() < aNewSubject.eval()){
								newPopulation.add(aNewSubject);
							}
							
						}
					}
				}
			}
			
			population.addAll(newPopulation);
			
			if (population.size() > maxPopulation)
				purgePopulation();
		}
	}