3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $str = '54 some gay way'; $parts = explode(' ', $str); if (sizeof($parts) > 1) { $number = $parts[0]; $address = implode(' ', array_slice($parts, 1, sizeof($parts) - 1)); } var_dump($number, $address);
Output for 4.3.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
string(2) "54" string(12) "some gay way"