A Hybrid Genetic Algorithm for a Logic Problem