I found this code in a RailsCast:
def tag_names @tag_names || tags.map(&:name).join(\' \') end
What does the (&:name)
(&:name)
It basically execute the method call tag.name on each tags in the array.
tag.name
It is a simplified ruby shorthand.