Let\'s say we have 0.00045. I want to find a way to count the number of \"significant\" zeros after the decimal point (3 in this case). I\'ve been trying to implement st
st
Match the first consecutive zeroes in the mantissa:
$number = 123.0000000240003; preg_match("/^(0+)/", explode('.', $number)[1], $matches); echo strlen($matches[0]); // echoes 7