Zend 200-550 Question Answer
What is the output of the following code?
class A {
public $a = 1;
public function __construct($a) { $this->a = $a; }
public function mul() {
return function($x) {
return $this->a*$x;
};
}
}
$a = new A(2);
$a->mul = function($x) {
return $x*$x;
};
$m = $a->mul();
echo $m(3);
Zend 200-550 Summary
- Vendor: Zend
- Product: 200-550
- Update on: Jan 2, 2026
- Questions: 223

