3v4l.org

run code in 300+ PHP versions simultaneously
<?php $server_seed = "96f3e04d221ca1b2048cc3b3b844e479f2bd9c80a870628072ee98fd1aa83cd0"; $public_seed = "12457898"; $round = "691"; $hash = hash('sha256', $server_seed . "-" . $public_seed . "-" . $round); $roll = hexdec(substr($hash, 0, 8)) % 15 + 1; if ($roll == 1) $roll_side = 'gold'; elseif ($roll == 2) $roll_side = 'blackbait'; elseif ($roll == 15) $roll_side = 'redbait'; elseif ($roll % 2 == 1) $roll_side = 'red'; elseif ($roll % 2 == 0) $roll_side = 'black'; echo("Roll: $roll\nColour: $roll_side");
Output for git.master, git.master_jit, rfc.property-hooks
Roll: 15 Colour: redbait

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:
40.28 ms | 405 KiB | 5 Q