Anonymous Functions & Closures
Anonymous functions are functions without a name. They can be stored in variables or passed as arguments.
Closures
Use use($var) to bring outer variables into the function's scope.
Arrow Functions (PHP 7.4+)
Short syntax: fn($x) => $x * 2. Automatically captures outer scope (no use needed).