3v4l.org

run code in 300+ PHP versions simultaneously
<?php function f($a,$b){return(int)$a==(int)$b;} $testCases = [ [["0001", "1 "], true], [["1450", "1450 "], true], [["0010001 ", " 10001 "], true], [["0010000", " 10 "], false], [["101023", "101024"], false], ]; foreach ($testCases as $testCase) { list($values, $expected) = $testCase; assert($expected === f(...$values)); }
Output for git.master, git.master_jit, rfc.property-hooks

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:
55.79 ms | 401 KiB | 8 Q