Skip to main content
1 de 5

Porque no puedo eliminar un objeto de una lista en python?

numbers = list(range(0,30,2)) for i in range(0,30): if numbers[i] % 2 == 0 and numbers[i] == 2: numbers[i] = 2 if numbers[i] % 2 == 0: numbers.remove(i) print(numbers)