send & public_send

Call a method by its name-as-data

send calls a method whose name you have as a symbol or string: booking.send(:confirm!) is the same as booking.confirm!. The power is that the name can be computed β€” from user input, a config value, a database column. This is how a generic controller can call record.public_send(params[:action]) or how a serializer reads every attribute by name.

In an interview, say: "send invokes a method from its name as data β€” essential when the method to call is determined at runtime. I default to public_send so I don't accidentally reach past an object's public interface."