3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class induk{ protected $tinggi=6; protected $alas=20; public function SetTinggi(){ return ($this->tinggi/2); } public function setAlas(){ return ($this->alas/2) } } $cp2 =new induk(); echo $cp2 ->SetTinggi echo $cp2 ->aetAlas
based on 0hdaI
Output for 7.0.28 - 7.3.0rc3
Parse error: syntax error, unexpected '}', expecting ';' in /in/d5nSo on line 12
Process exited with code 255.
Output for 5.6.38
Parse error: syntax error, unexpected '}' in /in/d5nSo on line 12
Process exited with code 255.