3v4l.org

run code in 200+ php & hhvm versions
<?php $value = 5.1 + ''; var_dump($value); $value = 5.4 * 'hi'; var_dump($value); $value = 5.4 + 'Tom'; var_dump($value);
based on XPEEl
Output for 7.1.0 - 7.3.5
Warning: A non-numeric value encountered in /in/LKAuG on line 3 float(5.1) Warning: A non-numeric value encountered in /in/LKAuG on line 6 float(0) Warning: A non-numeric value encountered in /in/LKAuG on line 9 float(5.4)
Output for 4.3.0 - 5.6.40, hhvm-3.10.1 - 3.22.0, 7.0.0 - 7.0.33
float(5.1) float(0) float(5.4)