(yet another) genetic algorithm