A simple string -> function utility for concise function definitions.