3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = 0.03; $b = 1 - 0.97; $c = (float)(string) 0.03; $d = (float)(string) (1 - 0.97); var_dump($a, $b, $a === $b, $c, $d, $c === $d); var_dump(sprintf('%1.20f', $b), sprintf('%1.20f', $d));
Output for git.master, git.master_jit, rfc.property-hooks
float(0.03) float(0.030000000000000027) bool(false) float(0.03) float(0.03) bool(true) string(22) "0.03000000000000002665" string(22) "0.02999999999999999889"

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