def attributes=(attributes = {})
      attributes.each do |name, value|
        begin
          send("#{name}=", value)
        rescue NoMethodError => e
          puts "Unable to assign #{name}. No such method."
        end
      end
    end
def attributes=(attributes = {})
      attributes.each do |name, value|
        begin
          send("#{name}=", value)
        rescue NoMethodError => e
          puts "Unable to assign #{name}. No such method."
        end
      end
    end
Set the attributes based on the given hash