-1

I want to remove Ben "True" data. How will I remove the true data?

customer_data = [["Ainsley", "Small", True], ["Ben", "Large", False], ["Chani", "Medium", True], ["Depak", "Medium", False]]

customer_data[2][2] = False
customer_data.remove()

print(customer_data)
Robert
  • 7,394
  • 40
  • 45
  • 64
Angelo
  • 1
  • 1

1 Answers1

0
for i in customer_data.copy():
    if "Ben" in i or True in i:
        customer_data.remove(i)
S.B
  • 13,077
  • 10
  • 22
  • 49
Tanveer Ahmad
  • 706
  • 4
  • 12