genetic algorithm for solving N-Queens