What is the output of the following code?var_dump(boolval([]));
Answer(s): B
What is the output of the following code?var_dump(boolval(new StdClass()));
Answer(s): A
CORRECT TEXTConsider the following code: $result = $value1 ??? $value2;Which operator needs to be used instead of ??? so that $result equals $value1 if $value1 evaluates to true, and equals $value2 otherwise? Just state the operator as it would be required in the code.
Which of the following is NOT true about PHP traits? (Choose 2)
Answer(s): B,E
Given the following code, what will the output be:trait MyTrait {private $abc = 1;public function increment() {$this->abc++;}public function getValue() {return $this->abc;}}class MyClass {use MyTrait;public function incrementBy2() {$this->increment();$this->abc++;}}$c = new MyClass;$c->incrementBy2();var_dump($c->getValue());
Answer(s): D
Post your Comments and Discuss Zend 200-550 exam prep with other Community members:
Our website is free, but we have to fight against AI bots and content theft. We're sorry for the inconvenience caused by these security measures. You can access the rest of the 200-550 content, but please register or login to continue.