3v4l.org

run code in 300+ PHP versions simultaneously
<?php function string_to_ascii($string) { $ascii = NULL; for ($i = 0; $i < strlen($string); $i++) { $ascii += ord($string[$i]); } return($ascii); } function calc($a, $b) { $l1 = strlen($a); $l2 = strlen($b); $l = min($l1, $l2); $r = ''; for($i = 0; $i < $l; $i++) { $r .= chr(ord($a[$i]) ^ ord($b[$i])); } return $r; } $a = "8112yuyuiuoui"; $b = "p90187opoipi[i[o[bnmmvhfdfhgj"; var_dump(calc($a, $b)); var_dump($a ^ $b);
Output for git.master, git.master_jit, rfc.property-hooks
string(13) "HAB2" string(13) "HAB2"

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