3v4l.org

run code in 200+ PHP versions simultaneously
<?php $number = 12.4444; $decimal = strlen(substr($number, strpos('.', $number) + 1)); var_dump($decimal);
Output for 7.3.0 - 7.4.1
Deprecated: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior in /in/Ikla1 on line 3 int(6)
Output for 4.3.0 - 7.2.26
int(6)