3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $ip = '192.168.21.1 - 192.168.21.254'; $ip = str_replace(' ', '',$ip); $ip = explode('-', $ip); list($lower, $upper) = $ip; $lower_dec = (float) sprintf("%u", ip2long($lower)); $upper_dec = (float) sprintf("%u", ip2long($upper)); echo ($lower_dec); echo ($upper_dec);
Output for 4.3.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
32322408973232241150