3v4l.org

run code in 300+ PHP versions simultaneously
<?php $tests = [ "€1000", "€66.66", "€-5.0005", ]; $result = []; foreach ($tests as $t) { sscanf($t, '€%d', $result["$t: asInteger"]); sscanf($t, '€%f', $result["$t: asFloat"]); } var_dump($result);
Output for git.master_jit, git.master, rfc.property-hooks
array(6) { ["€1000: asInteger"]=> int(1000) ["€1000: asFloat"]=> float(1000) ["€66.66: asInteger"]=> int(66) ["€66.66: asFloat"]=> float(66.66) ["€-5.0005: asInteger"]=> int(-5) ["€-5.0005: asFloat"]=> float(-5.0005) }

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:
33.63 ms | 406 KiB | 5 Q