https://github.com/ahmedfgad/GeneticAlgorithmPython/blob/251072766d8a9f3ea03ab41f74cda2e8c20c21d0/example_custom_operators.py#L58 Easy fix. It Should be ``` random_gene_idx = numpy.random.choice(range(offspring.shape[1]))```