15 Now you Try! Says I'm missing something, don't see it


#1

Here is my code:

my_array = ["raindrops", :kettles, "whiskers", :mittens, :packages]

# Add your code below!
symbol_filter= lambda {|n| n.is_a?Symbol}
my_array.select(&symbol_filter)

I've checked the other threads and I don't see anyone with this problem; I don't get syntax errors or anything, everything looks fine to me. But I get the error:

"Oops, try again. Your symbols array should include kettles, but doesn't."

But the output DOES have kettles. It says [:kettles, :mittens, :packages]

I don't know if I can fix this with code, with changing the array, I can't tell why this is happening.
Thanks.


#2

This needs to be assigned to a variable according to instruction 02.


#3

Wow.
I can't believe I skipped that. Thanks.


#4

my_array = ["raindrops", :kettles, "whiskers", :mittens, :packages]

Add your code below!

symbol_filter = lambda { |n| n.is_a?Symbol }
symbols = my_array.select(&symbol_filter)


#5

@rubysurfer52871

Put a space between ? and Symbol


#7