3v4l.org

run code in 300+ PHP versions simultaneously
<?php //$input = file_get_contents('php://stdin','r'); //$params = explode("\n",$input); $params = [3,3,60,100]; $probes = shift_array($params); function silnia($n) { return ($n <= 1) ? 1 : gmp_mul($n, silnia($n-1)); } function z($silnia) { $strSilnia = (string)$silnia; $zeroCount = 0; for ($i = strlen($strSilnia)-1; $i >= 0; $i--) { if ($strSilnia[$i] == 0) $zeroCount += 1; else break; } echo $zeroCount.PHP_EOL; } for ($i = 0; $i < $probes; $i++) { z(silnia($params[$i])); }
Output for git.master, git.master_jit, rfc.property-hooks
Fatal error: Uncaught Error: Call to undefined function shift_array() in /in/lB5HJ:6 Stack trace: #0 {main} thrown in /in/lB5HJ on line 6
Process exited with code 255.

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
52.91 ms | 401 KiB | 8 Q