3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = 10000; $b = 11111; $c = $a & $b; $r = $a ^ $b; var_dump(decbin($a), decbin($b), decbin($c), decbin($r), '---'); while ($c) { $shift = $c << 1; $c = $r & $shift; $r ^= $shift; var_dump(decbin($s), decbin($c), decbin($r), '---'); } var_dump($r);
Output for git.master, git.master_jit, rfc.property-hooks
string(14) "10011100010000" string(14) "10101101100111" string(14) "10001100000000" string(12) "110001110111" string(3) "---" Warning: Undefined variable $s in /in/rhUud on line 15 Deprecated: decbin(): Passing null to parameter #1 ($num) of type int is deprecated in /in/rhUud on line 15 string(1) "0" string(11) "10000000000" string(15) "100101001110111" string(3) "---" Warning: Undefined variable $s in /in/rhUud on line 15 Deprecated: decbin(): Passing null to parameter #1 ($num) of type int is deprecated in /in/rhUud on line 15 string(1) "0" string(12) "100000000000" string(15) "100001001110111" string(3) "---" Warning: Undefined variable $s in /in/rhUud on line 15 Deprecated: decbin(): Passing null to parameter #1 ($num) of type int is deprecated in /in/rhUud on line 15 string(1) "0" string(1) "0" string(15) "101001001110111" string(3) "---" int(21111)

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:
46.65 ms | 402 KiB | 8 Q