Question:What will be output of the following code?class test{ private $a; function set($x){ $this->a =$x; } public function get(){ return $this->a; } } $t1 = new test; $t1->set(10); echo $t1->get();
class test{ private $a; function set($x){ $this->a =$x; } public function get(){ return $this->a; } } $t1 = new test; $t1->set(10); echo $t1->get();
A 0 B 10 C Error D None
+ AnswerB
+ Report