code: def mutate(self):
          
          # Choose a random position
          if len(self.code) == 0:
              return
  
          index = random.randint(0, len(self.code)-1)
          mutation_type = random.random()
  
          if mutation_type < 0.5:
              # Change
              self.code[index] = self.new().randomize().code[0]
          elif mutation_type < 0.75:
              # Deletion
              del self.code[index]
          else:
              # Insertion
              self.code.insert(index, self.new().randomize().code[0])
docs: Mutates code.