14. String interpoloation

Why is this not accepted?

favorite_things = [“Ruby”, “espresso”, “candy”]

puts “A few of my favorite things:”

favorite_things.each do |thing|
puts “I love #{thing} !”
end

Hi @jaydacoder ,

In the following statement, you have a space just before the exclamation point, that needs to be removed …

puts "I love #{thing} !"
3 Likes

It worked, thanks!

So I did grasp the concept, just that CC was being exactly precise. Good to know. Thanks!

what is the answer @jaydacoder

The answer is

     favorite_things = ["Ruby", "espresso", "candy"]

     puts "A few of my favorite things:"

     favorite_things.each do |thing|
         puts "I love #{thing}!"
     end

DO NOT put a space after #{thing}

Thanks for your help. had the same problem here.