Why doesn't this work? ```val moreColors = arrayLi...
# react
d
Why doesn't this work?
Copy code
val moreColors = arrayListOf("blue, red, yellow, pink, teal, red")

// Create a new array list to store the colors without "red"
val newColors = moreColors.filter { it != "red" }

// Print the newColors array list
println(newColors)
k
shouldn't be
arrayListOf("blue", "red", "yellow", "pink", "teal", "red")
?
b
Works just fine
d
No idea why it wasn't working for me initially
Thanks