solving n queens using genetic algorithm