3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php // liczba caƂkowita w reprezentacji binarnej ile jest 1 function ileJedynekWBin($liczba) { $temp = decbin($liczba); $return = 0; for($i=0;$i<strlen($temp);$i++){ if($temp[$i]) == '1') $return++; } return $return; } echo ileJedynekWBin(7); ?>
Output for 5.4.0 - 5.4.15
Parse error: syntax error, unexpected '==' (T_IS_EQUAL) in /in/4i1UU on line 7
Process exited with code 255.
Output for 5.3.25
Parse error: syntax error, unexpected T_IS_EQUAL in /in/ccUqA on line 7
Process exited with code 255.
Output for 5.3.0 - 5.3.24
Parse error: syntax error, unexpected T_IS_EQUAL in /in/4i1UU on line 7
Process exited with code 255.